The appeal is by the defendant Morgan L. Ketchum, from portions of the judgment, and no point is made by respondent that the judgment of the superior court is not final and appealable.
It is not necessary to decide whether the court below did or did not err in overruling the demurrer to the complaint of the defendants Ketchum and the Bank of Watsonville. If it be conceded the demurrer was properly overruled, the portions of the judgment appealed from must still be reversed.
And even if upon the complaint a judgment decreeing an accounting and for a redemption from the mortgages of the defendants Ketchum and the bank would, under any circumstances, have been justified, the portions of the judgment from which an appeal has been taken must be reversed.
The superior court decreed a dissolution of the marriage between plaintiff and the defendant William N. Cummings; that plaintiff was entitled to the custody of the infant daughter, sole issue of the marriage; and that defendant Cummings pay to the plaintiff fifty dollars a month as alimony and a sum as suit-money; and further decreed that the property described in the complaint was, at the commencement of the suit, charged with the mortgage in the judgment afterward referred to; that the said .property or tract of land be divided equally, share *437and share alike, etc., between the plaintiff and the defendant Cummings, and in case they cannot agree upon a partition, Bart Burke, Esq., be appointed a commissioner to make and report such a partition, etc.; that the share set apart to the defendant Cummings be charged with the payment of costs, alimony, and counsel fees awarded to the plaintiff, and the same be a lien thereon; that the instrument of the 18th of May, 1876, purporting to be a deed from defendant Cummings to defendant Ketchum, is and was intended to be a mortgage to secure the payment of fifteen hundred dollars and interest, and not a deed conveying the land, otherwise than as security, and that the instrument was and is a valid and binding mortgage, free from fraud; that the property is subject to and bound for the payment of the unpaid portion of the mortgages of the Bank of Watsonville and Ketchum; that Ketchum is entitled to a lien on the land for the sum of fifteen hundred dollars and interest thereon from tenth day of June, 1874, to the tenth day of February, 1876, at the rate of one and one half per cent per month, and with legal interest thereon from the last date to the entry of decree, “ less whatever sums of money he may have received as rent or otherwise from the premises held by him under the said instrument, herein declared to be a mortgage, over and above what he has expended thereon for taxes, repairs, and in payment of the principal or interest on the Bank of Watson-ville mortgage”; that for the purpose of ascertaining, etc., Bart Burke is appointed a referee to ascertain and report the amount of deductions, if any, to be made, “ and to make and state said account between said Ketchum and his said receipts from said property,” etc.; that as between said plaintiff and defendants Cummings and Ketchum, and those claiming under them, the part or half of the premises awarded to plaintiff be chargeable with the payment of “one half of the Ketchum and Bank of Watsonville mortgages”; that Bart Burke, *438Esq., be appointed a receiver to receive the rents, profits, and issues of the land until further order, to be paid out by him under direction of the court: 1. For taxes; 2. For . repairs; 3. For the support of plaintiff and her child; 4: For costs and counsel fees; 5. For interest due and accruing on the Bank of Watsonville mortgage.
The judgment recites that the plaintiff having introduced her evidence in chief, a nonsuit was granted as to the defendant the Bank of Watsonville. The dismissal, or nonsuit in favor of the bank, of itself, might perhaps only show that the bank had no interest in of lien upon the property. But the final judgment declares that the property described is subject to and bound by the unpaid portion of the mortgage of the Bank of Watsonville, and that the defendant Ketchum is entitled to a lien for the amount of his mortgage, less what he may have received as rents, etc., over and above what he has expended for taxes, repairs, and in the payment of principal or interest “ on the Bank of Watsonville mortgage”; further, that the referee ascertain what Ketchum has paid for principal or interest of the bank mortgage. And the receiver is directed to pay out the rents by him received, the alimony and the costs and counsel fees awarded, before paying interest on the mortgage of the bank.
It is apparent that the bank is a necessary party to the accounting. Its mortgage is recognized as valid in' the judgment, and no decree could properly be entered determining what sums had been paid to it by the defendant Ketchum, or giving priority to the alimony or suit money in the absence of the bank. The mortgage of the bank would seem to be a mortgage executed by defendant Ketchum, and in view of the nonsuit and the recognition of the mortgage in the decree, it cannot .be presumed that it was taken with notice that the instrument from the defendant Cummings to Ketchum was-other than it purports to be,—a deed absolute. Even, therefore, if the decree, as between the plaintiff and appel*439lant Ketchum, could have been upheld if the bank had been a party defendant, it should be reversed, with directions to the court below to cause the bank to be brought in and reinstated as a defendant, as being a necessary party without whose presence the rights of the other parties could not be finally determined.
The portion of the decree which provides for a commissioner to make partition of the land described would, in any event, be reversed. In an action for divorce the court may, in certain instances, “ divide ” the common real estate. (Civ. Code, sec. 146.) But this does not authorize an actual partition of the land in every instance. Here the land was in the rightful possession of Ketchum, who had a valid lien extending to every portion of it, and there should have been no decree for a partition until the lien was satisfied or redeemed. Aside from the fact that such entry and partition would be an unlawful interference with the occupation of a mortgagee in the rightful possession, the rights of the respective spouses in the property may depend upon and be affected by the fact that the one or the other shall redeem the mortgages.
Nor, in any view of the case, could that part of the decree which provides that the one half of the property awarded to the plaintiff shall be chargeable with the payment of only one half of the Ketchum mortgage be permitted to stand. The defendant Ketchum having a valid mortgage upon all the land, the court was not justified in attempting to limit or change the liability created by it, or in altering in any way his rights or the obligations of the community under his contract.
And so of that part of the decree relating to a receiver. Ketchum, a mortgagee in good faith and in possession, was authorized to remain in possession with the equitable right of protecting his security, by paying the taxes and keeping the property in repair, and of applying the excess of the rents and profits to the payment first of the *440interest and then of the principal of his mortgage. Yet, without any averment or finding that he had committed waste or abused his position, the court appointed a receiver to collect and receive the rents and profits, and to pay them out, giving priority to alimony and counsel fees over the claim of the mortgagee.
But the portions of the decree above specified must be reversed for another reason: they are not based upon any pleading in the cause.
The complaint, filed April 28, 1883, avers that the defendants Cummings and Ketchum combined and confederated together for the purpose and with the intent of cheating and defrauding the plaintiff out of her rights and interests in a certain described tract of land, part of the community property of herself and defendant Cum-, mings; and that to carry out such fraudulent design, on the 18th of May, 1876, the defendant Cummings executed and delivered to the defendant Ketchum, and the latter received, an instrument purporting to be a deed of conveyance of the property described, the consideration therein recited being eight thousand dollars; that in truth and in fact no consideration whatever was paid therefor, the sole purpose of the parties to the instrument being to cheat and defraud the plaintiff as aforesaid, and to cover up and conceal the title of the community in said land.
The answer of the defendant Ketchum denies the allegations of the complaint.
The court found that in the execution and acceptance of the deed of the 18th of May, 1876, there was no design or plan on the part of William N. Cummings and Morgan L. Ketchum, or either of them, to impair or defeat or affect in any way the rights of the plaintiff.
But the court also found that the deed, although absolute in form, was executed by said Cummings and received by said Ketchum as security for a debt of fifteen hundred dollars, which sum and the interest thereon *441remains unpaid; and as conclusion of law, that there •was no fraud in the deed from Cummings to Ketchum, but that the same was a mortgage, and a valid lien for fifteen hundred dollars and interest.
The complaint herein is not framed as a bill to redeem the Ketchum and Bank of Watsonville mortgages, or either of them, and it contains no averments on which can be founded a decree for redemption. Nor are there allegations that defendant Ketchum is a mortgagee in possession on which could be based a decree that he account for the rents and profits; this, independent of the mere fact that the plaintiff does not offer to redeem. No supplemental complaint was filed or offered containing allegations such as would justify the decree entered as against the defendant Ketchum. On the contrary, the complaint expressly denies that Ketchum has any interest in the premises, averring that the deed purporting to convey the legal title was void, made in fraud of the plaintiff’s rights, and without consideration.
Where a defendant has answered, the court may grant the plaintiff "any relief consistent with the case made by the complaint, and embraced within the issue.” (Code Civ. Proc., sec. 530.) Here the relief which the court below attempted to grant the plaintiff, as against the appellant, was neither consistent with the case made by the complaint nor embraced within the issues made by the answer.
In Gregory v. Nelson, 41 Cal. 278, it was held that if a judgment in equity decrees the existence of facts not within any issues made or tendered by the pleadings, and then pronounces the judgment of the court upon such facts, such part of the judgment “is superfluous and nugatory.” In Burnett v. Stearns, 33 Cal. 474, the supreme court said: “The province of the court with respect to facts is to determine, but not to raise, the issue.”
A judgment for the plaintiff must be limited by the *442facts stated in the complaint. Where the defendant has answered, the court may, under the general prayer, grant any relief consistent with the complaint, with the facts' alleged in the complaint; but under the general prayer,no relief can be granted in equity beyond that which is authorized by the facts stated in the pleadings. (Carpentier v. Brenham, 50 Cal. 549.)
The court below would have been justified in decreeing that the property specifically described was, as between the plaintiff and defendant Cummings, at the commencement -of the action, community property of the spouses, to the extent of any estate therein which had not been conveyed or transferred by the defendant Cummings.
The cause is remanded, and the court below is directed to modify as above indicated the part of the judgment which decrees the property described as community property, or by otherwise expressly saving and preserving the estates in the premises, if any they have, of the defendants other than defendant Cummings, and all or any rights the said defendants, or either of them, other than Cummings, may have in or upon said premises by way of mortgage, lien, or encumbrance. The other portions of the decree appealed from are reversed, and the court below is directed to enter instead thereof a judgment in favor of the appellant.
Temple, J., Searls, C. J., Sharpstein, J., and Paterson, J., concurred.