Civil Procedure Code 580e
580e. (a) (1) No deficiency shall be owed or collected, and no deficiency judgment shall be requested or rendered for any deficiency upon a note secured solely by a deed of trust or mortgage for a dwelling of not more than four units, in any case in which the trustor or mortgagor sells the dwelling for a sale price less than the remaining amount of the indebtedness outstanding at the time of sale, in accordance with the written consent of the holder of the deed of trust or mortgage, provided that both of the following have occurred:
(A) Title has been voluntarily transferred to a buyer by grant deed or by other document of conveyance that has been recorded in the county where all or part of the real property is located.
(B) The proceeds of the sale have been tendered to the mortgagee, beneficiary, or the agent of the mortgagee or beneficiary, in accordance with the parties' agreement.
(2) In circumstances not described in paragraph (1), when a note is not secured solely by a deed of trust or mortgage for a dwelling of not more than four units, no judgment shall be rendered for any deficiency upon a note secured by a deed of trust or mortgage for a dwelling of not more than four units, if the trustor or mortgagor sells the dwelling for a sale price less than the remaining amount of the indebtedness outstanding at the time of sale, in accordance with the written consent of the holder of the deed of trust or mortgage. Following the sale, in accordance with the holder's written consent, the voluntary transfer of title to a buyer by grant deed or by other document of conveyance recorded in the county where all or part of the real property is located, and the tender to the mortgagee, beneficiary, or the agent of the mortgagee or beneficiary of the sale proceeds, as agreed, the rights, remedies, and obligations of any holder, beneficiary, mortgagee, trustor, mortgagor, obligor, obligee, or guarantor of the note, deed of trust, or mortgage, and with respect to any other property that secures the note, shall be treated and determined as if the dwelling had been sold through foreclosure under a power of sale contained in the deed of trust or mortgage for a price equal to the sale proceeds received by the holder, in the manner contemplated by Section 580d.
(b) A holder of a note shall not require the trustor, mortgagor, or maker of the note to pay any additional compensation, aside from the proceeds of the sale, in exchange for the written consent to the sale.
(c) If the trustor or mortgagor commits either fraud with respect to the sale of, or waste with respect to, the real property that secures the deed of trust or mortgage, this section shall not limit the ability of the holder of the deed of trust or mortgage to seek damages and use existing rights and remedies against the trustor or mortgagor or any third party for fraud or waste.
(d) (1) This section shall not apply if the trustor or mortgagor is a corporation, limited liability company, limited partnership, or political subdivision of the state.
(2) This section shall not apply to any deed of trust, mortgage, or other lien given to secure the payment of bonds or other evidence of indebtedness authorized, or permitted to be issued, by the Commissioner of Corporations, or that is made by a public utility subject to the Public Utilities Act (Part 1 (commencing with Section 201) of Division 1 of the Public Utilities Code).
(e) Any purported waiver of subdivision (a) or (b) shall be void and against public policy.