[Direct answer]In the Beijing area, the principle of "the lease remains effective even after the ownership of the leased property changes" is an explicit rule of the Civil Code: if the ownership of the leased property changes during the lease term specified in the lease contract, it does not affect the validity of the lease contract; if the landlord sells the house, the tenant does not need to move out. The new landlord automatically assumes the position of the lessor, and the tenant can continue to live in the house and pay the rent to the new landlord; at the same time, the tenant also holds the right of first refusal. If the landlord fails to notify the tenant within a reasonable period before selling the house, the tenant can claim compensation. What the tenant really needs to guard against are two points: if the lease contract is not registered and filed, it does not affect the rights but affects the provision of evidence when opposing third parties; and the protection of "the lease remains effective even after the sale" on the property with a mortgage preceding the lease may fail.

1. Problem background and typical scenarios

There are still two years left in the lease, but the landlord suddenly announced, "The house has been sold, and you need to move out by the end of the month." Or, the new landlord might demand a rent increase and require a new lease agreement immediately after taking over—the negotiation between tenants and landlords during the lease period is the scenario where tenants are most likely to suffer losses and are most likely to receive legal support.

II. Key points of contention

First, the effectiveness of the lease contract towards the new landlord. Second, the exercise of the preemptive right and compensation. Third, the impact of mortgages and seizures on lease protection. Fourth, the transfer of the deposit and rent.

III. Professional analysis by Henglue Lawyers

First, the basic rule: If the lessee occupies and uses the leased property during the lease term, the change of ownership of the house during the lease period does not affect the validity of the lease contract—the new landlord buys the "house with a lease agreement", and his rights and obligations are generally inherited, without the right to unilaterally require the tenant to vacate the premises in advance; the tenant continues to live in the house according to the original contract until the lease expires, and the rent standard, deposit terms, and maintenance obligations remain unchanged; unless the tenant agrees, any amendment to the original contract must be negotiated with the tenant himself/herself. Second, the preemptive right: The landlord shall notify the lessee within a reasonable period before the sale, and the lessee enjoys the right of preemption under the same conditions—the notice must be delivered within a reasonable period (usually 15 days in practice). If the lessee does not expressly indicate his/her intention to purchase within 15 days after receiving the notice, it shall be deemed that he/she has waived the right; if the new landlord or the landlord infringes the preemptive right, the lessee may request compensation for losses, but cannot claim that the house sale contract is invalid or rescinded—the compensation does not rescind the sale contract, which is the clear boundary of the current rules. Third, two exceptions must be recognized: In the case of leasing after mortgage, the lease relationship cannot be opposed to the transferee when the mortgage right is realized—check whether the house has a prior mortgage registration when viewing the house, and if it is not lifted before signing the lease, the stability of the lease will be inherently insufficient; if the house is rented out after being sealed by the court, the lease cannot be opposed to the enforcement disposal—if the lease exists before the seizure and the tenant actually occupies and lives in the house, the protection can still continue. Fourth, the money must be settled with the rightful owner: If the landlord fails to settle the water, electricity, gas and rent when selling the house, the tenant should keep evidence to claim offset from the new landlord; the deposit shall be transferred to the new landlord together with the lessee's status, and the tenant should claim it from the new landlord upon vacating the premises, rather than being dismissed with the excuse of "asking the old landlord for the deposit"—the settlement agreement between the original landlord and the new landlord cannot be against the tenant; when selling with a lease, the tenant can also confirm the transfer of the deposit and expenses with the new and old landlords in writing, and a confirmation letter can avoid future disputes among the three parties.

IV. Practical suggestions and legal basis

The first step is to receive the notice of selling the house and confirm in writing that the lease contract remains valid; the second step is to check the status of the house mortgage and seizure to assess the stability of the lease; the third step is to exercise the right of first refusal within 15 days and express it in writing; the fourth step is for all three parties to confirm the acceptance of the deposit and retain all the evidence of the entire transaction chain. The main legal basis: Articles 725, 726, 728, and 729 of the Civil Code of the People's Republic of China, and the relevant provisions of the Judicial Interpretation of the Supreme People's Court on the Trial of Urban Housing Lease Contract Disputes; the specific application shall be subject to the currently effective provisions.

5. Henglu Law Firm's Advice

Three key points regarding the sale of a house with a lease: the lease remains valid after the sale; the new landlord inherits all rights and obligations; and the tenant has the right to purchase the property within 15 days. If the tenant's rights are infringed, they can claim compensation without withdrawing from the sale. However, if the mortgage precedes the lease, the protection for the tenant's rights may fail, and the transfer of the deposit must be confirmed by all three parties. This case was handled by Beijing Henglu Law Firm.Li YonghuiThe attorney (practice license number: 11101199611955812, subject to the document issued by the judicial administrative organ) acts as an agent. For disputes involving lease contracts, you can proceed through the following channels:Property sales and construction projectsYou can combine the review of contract terms with obtaining an overall solution for the service.Business and contract disputes in enterprisesFor plate disputes involving payment disputes, you can refer to the following for resolution guidance.Creditor's rights and debts, and enforcementFor any questions regarding difficult situations, please feel free to consult us through the columnSpecial servicesTeam.

VI. Frequently Asked Questions

Q1: Can the new landlord ask me to move out early?

No. Changes in ownership during the lease period do not affect the validity of the lease contract, and the tenant has the right to stay until the lease expires.

Q2: Who should I pay the rent to?

After the new landlord takes over the lessor's position, the deposit will be transferred to the new landlord. Any disputes during the handover period shall be settled based on written notifications, to avoid being deemed as arrears in payment.

Q3: Do I have a priority purchase right?

Yes. The landlord should notify the tenant within a reasonable period of time before selling the property. Under the same conditions, the tenant has the priority to purchase it. If the landlord fails to notify the tenant, the tenant can claim compensation.

Q4: Who should I ask for the deposit?

The deposit shall be transferred to the new landlord upon the transfer of the lessor's status, and the tenant shall claim it from the new landlord when moving out. It is most secure to confirm this in writing by all three parties involved.

Q5: If the house is mortgaged, can the lease still be maintained?

For those who mortgage their property before renting it out, the lease cannot be used to oppose the transferee when the mortgage right is realized; it is crucial to check the mortgage registration before signing the contract.

The above answer is based on the judicial practice in Beijing. The judicial interpretation in other provinces and cities may differ. For specific cases, please refer to the local rules and evidence situation.

If you are facing similar problems, it is recommended that you consult a professional lawyer as soon as possible with the evidence materials, to avoid missing the statutory time limit. →Legal services for real estate transactions·Beijing Henglu Law Firm

Disclaimer: This article is compiled based on the current laws and regulations and publicly available adjudication rules, and is for general reference only. It does not constitute a formal legal opinion on specific cases. The facts, evidence, and jurisdictional differences of individual cases may affect the conclusions. In case of disputes, please consult a practicing lawyer in time.