YOUR PROPERTY IS OUR PRIORITY+34 951 255 878
All articles
Property tax & selling

Capital Gains Tax When Selling Property in Spain

Understand your position before you sell, buy or renovate. A practical guide to Spanish capital gains tax, main-home reinvestment relief, renovation costs and the rules for residents and non-residents.

Capital Gains Tax When Selling Property in Spain

Guidance checked on 6 November 2026. Your adviser should confirm the rules applying to your sale.

Selling a property on the Costa del Sol often brings a practical question: how much of the sale money will you have available for your next move?

The answer depends on more than the selling price. Your original purchase costs, improvements, ownership share, tax residence and eligibility for relief can all affect the calculation.

Buying another property can sometimes reduce or eliminate the Spanish capital gains tax on a sale. But there is no general rule allowing everyone to roll their profit into another house tax-free. Spending money on renovations does not automatically qualify either.

This guide explains the main distinctions for individual owners selling Spanish residential property, including Spanish residents and people living in the UK, elsewhere in Europe, the United States or China.

Start with your tax residence

The first question is where you are tax resident, rather than which passport you hold.

A British citizen who is tax resident in Spain will generally fall under the Spanish resident income-tax rules. A Spanish citizen living as a tax resident in the UK may instead fall under Spain’s non-resident rules when selling a Spanish property.

Spain’s residence tests include spending more than 183 days in the country during the calendar year and having the main centre of economic interests here. Family circumstances can also matter. Where two countries consider someone resident, the relevant tax treaty needs to be considered. An NIE number or ownership of a Spanish home does not, by itself, settle the question.

Your tax positionGeneral position on main-home reinvestment relief
Tax resident in SpainPotentially available when both homes and the reinvestment meet the conditions.
Tax resident in another EU country, Iceland, Norway or LiechtensteinPotentially available when selling a qualifying former main home in Spain, subject to the conditions.
Tax resident in the UK and non-resident in SpainThis particular reinvestment exemption generally is not available.
Tax resident in the United States or China and non-resident in SpainThis particular reinvestment exemption generally is not available.

Being “European” is not enough on its own: the relief refers to specified EU and EEA residence conditions. Equally, a British, American or Chinese passport does not prevent someone who is Spanish tax resident from qualifying under the Spanish resident rules.

A quiet Mediterranean terrace with a document folder and notebook, illustrating planning a property sale.

What is the taxable gain?

Capital gains tax is generally calculated on the gain made on the property, rather than its full sale price.

Sale price, less allowable selling expenses, minus the adjusted acquisition cost.

The acquisition cost can include the original purchase price, eligible purchase taxes and expenses, and qualifying capital improvements. Allowable selling expenses can reduce the disposal value where they were paid by the seller.

If the property has been rented out, tax depreciation can reduce its acquisition value and increase the eventual gain. This can apply even where the owner did not actually claim all the depreciation that should have been taken into account.

ItemIllustrative amount
Sale price€500,000
Less allowable selling expenses€20,000
Net disposal value€480,000
Original purchase price€300,000
Eligible purchase taxes and expenses€25,000
Documented qualifying capital improvements€15,000
Adjusted acquisition cost€340,000
Gain before exemptions or other adjustments€140,000

This simplified example assumes no rental depreciation or other special adjustments.

An outstanding mortgage does not normally reduce the capital gain itself. Repaying the bank changes the cash you receive. It can also affect the reinvestment calculation, which is a separate question.

How much tax do Spanish residents pay?

For an individual taxed under the ordinary Spanish resident rules applicable in Andalucía, taxable property gains generally enter the savings tax calculation.

Slice of taxable savings income and gainsRate
First €6,00019%
€6,000 to €50,00021%
€50,000 to €200,00023%
€200,000 to €300,00027%
Above €300,00030%

These are progressive bands. Reaching a higher band does not mean the whole gain is taxed at that rate. Other savings income, gains, allowable losses and personal circumstances can affect the result.

As a simple illustration, a €100,000 taxable gain, with no other savings income, losses or relevant adjustments, produces tax of €21,880 under this scale.

How much do non-residents pay?

For an individual non-resident selling Spanish property, the Spanish tax rate on the taxable capital gain is generally 19%.

This property-gain rate also applies to UK-resident sellers. It should not be confused with the different rates that can apply to other types of non-resident income.

Your country of tax residence may also require the sale to be reported. Any additional liability and relief for Spanish tax depend on that country’s rules and the relevant treaty. A Spanish calculation should therefore be checked alongside your home-country position.

Can buying another home remove the tax?

Potentially, if you qualify for main-home reinvestment relief, known in Spanish as exención por reinversión en vivienda habitual.

People sometimes call this “capital gains deferral” or “rollover relief”. However, when its conditions are fulfilled, the Spanish rule exempts the qualifying gain rather than simply postponing the same tax until a later sale.

The relief normally requires the sale of a qualifying main home and reinvestment in another qualifying main home. Reinvestment can take place within two years before or after the sale, calculated from the relevant dates.

Partial reinvestment can give partial exemption. The relief is not automatic and must be properly reflected in the relevant tax filing.

What counts as a main home?

A main home is not simply a property you own or occasionally use.

It normally needs to have been your actual home for at least three continuous years, although circumstances requiring an earlier move can qualify for exceptions. The replacement home generally needs to be occupied effectively and permanently within 12 months of acquisition or completion of the relevant works.

For the sale exemption, the old home can generally qualify if it was your main home at the sale date or at some point during the preceding two years. A holiday apartment does not qualify just because it is your only Spanish property.

Do you reinvest the profit or the proceeds?

For full exemption, the calculation generally looks at the net disposal proceeds, reduced by qualifying outstanding acquisition-mortgage principal—not merely the profit.

Suppose you sell for €500,000, have €20,000 of allowable selling expenses and repay €100,000 of qualifying outstanding acquisition mortgage:

Reinvestment calculationAmount
Sale price€500,000
Less allowable selling expenses€20,000
Less qualifying outstanding mortgage principal€100,000
Amount to reinvest for full relief€380,000

The acquisition value of the replacement home, including eligible acquisition expenses, then needs to be assessed against that amount. Mortgage financing of the replacement purchase does not, by itself, prevent relief.

If only 80% of the required amount is qualifying reinvestment, generally 80% of the gain is exempt and 20% remains taxable.

The ownership share also matters. Paying the entire purchase price does not necessarily allow you to count your partner’s share as your own reinvestment. A July 2026 Central Economic Administrative Tribunal decision confirms that qualifying reinvestment is limited by the taxpayer’s ownership proportion in the new property.

A Spanish kitchen renovation with oak cabinetry and tile samples, illustrating the distinction between refurbishment and qualifying rehabilitation.

Can kitchens, bathrooms and renovation costs count?

There are two different tax questions here, and they should be kept separate.

Improvements to the property you are selling

Documented capital improvements to the property being sold may increase its acquisition cost and reduce the taxable gain.

Repairs and maintenance are treated differently. A kitchen or bathroom project cannot be classified from its name alone: the scope of work determines whether it is an improvement or simply repair and replacement. Keep detailed invoices, payment records and supporting documentation for your adviser to assess.

Renovations to the replacement home

For main-home reinvestment relief, the test is stricter.

The Spanish Tax Agency expressly distinguishes qualifying rehabilitation from ordinary refurbishment. It excludes ordinary redistribution and modernisation work such as plumbing, electrical installations, flooring, tiling and carpentry from the structural rehabilitation concept.

A new kitchen, bathroom or comprehensive interior refurbishment therefore does not automatically count as qualifying reinvestment.

One qualifying route requires the principal purpose of the project to be reconstruction through structural, façade, roof or similar work. The total cost must exceed 25% of the relevant purchase price or market value, excluding the land element. The applicable valuation depends on when the property was acquired.

There is also a separate route for specified subsidised rehabilitation work. Neither route means that any expensive renovation qualifies.

Before relying on a renovation budget for relief, have the project assessed against the tax rules. A builder’s description of a “full renovation” is not sufficient confirmation.

What if you are buying an investment property?

The main-home exemption is not a general investment scheme.

Buying a holiday home, buy-to-let apartment or property to renovate and resell does not, by itself, exempt the gain on the property you have sold.

For a non-resident who qualifies through EU or EEA residence, the Spanish property sold must also meet the former-main-home conditions. Owning a holiday property in Spain while living elsewhere is not enough.

Why is 3% withheld from a non-resident’s sale?

When the seller is non-resident, the buyer must normally withhold 3% of the agreed sale price and pay it to the Spanish Tax Agency. On a €500,000 sale, that is €15,000.

This is a payment on account, rather than a separate additional capital gains tax. The seller calculates the actual liability and credits the withholding against it. An excess can be reclaimed; a shortfall remains payable. The withholding requirement still applies where an eligible non-resident intends to claim reinvestment relief.

The buyer normally files Modelo 211 within one month. The seller’s property-sale Modelo 210 is generally due during the following three months—even where the calculation produces no tax payable.

Eligible non-residents who reinvest later may need to use the separate Modelo 228 refund procedure, which has its own deadline.

Plusvalía municipal is a separate tax

There is another potential bill to consider: plusvalía municipal, formally IIVTNU.

This is a local tax concerning the increase in value of urban land. It is separate from the national capital gains calculation. Qualifying for main-home reinvestment relief does not automatically remove it.

The legislation provides for cases where no land-value increase has occurred and allows the actual increase to be used where it is lower than the statutory calculation, subject to the evidence and procedure required.

The relevant Ayuntamiento’s rules and filing process need to be checked. For example, Benalmádena’s official procedure specifies 30 working days from the deed date for lifetime transfers, while Mijas provides its plusvalía forms through its tax-management service.

A finished Mediterranean living room opening onto a terrace, illustrating planning the next property purchase.

What should you check before agreeing your next purchase?

Get the calculation prepared while you are planning the move. Gather:

  • Your original purchase deed and ownership percentage.
  • Purchase taxes, legal, notary and registration costs.
  • Invoices and payment evidence for improvements.
  • Rental history and relevant tax records.
  • Expected sale price and selling expenses.
  • Outstanding mortgage principal and its original purpose.
  • Evidence of tax residence and occupation as your main home.
  • Replacement-purchase details and any proposed rehabilitation project.

Ask your adviser to distinguish three figures: the taxable gain, the tax payable and the cash you will have available after completion. They are not the same thing.

Planning your next move on the Costa del Sol

A clear tax estimate makes it easier to set a realistic purchase budget, particularly when the next property needs work.

Costa Space can help you assess your selling position and explore suitable properties. For confirmation of your tax liability, residence status or eligibility for relief, use a qualified tax adviser who can review your documents and circumstances.

Talk to Costa Space about selling your property, or contact our team to discuss your next move.

Official sources and further reading

This article provides general information for individual property owners. It does not cover every exemption, historic acquisition rule, business structure or cross-border situation, and is not personalised tax advice. The photographs are illustrative and do not depict a specific property offered for sale.

See how we sell your homeBack to the journal
SELL WITH COSTASPACE

Your home. Our personal attention.

Thinking about selling on the Costa del Sol? Tell us about your property and let’s discuss the next step.

WhatsApp