Something that both residents and non-residents in Spain must once during their life in the country. The capital gains tax in Spain is one of the main taxes you will need to pay after obtaining a profit from an economic transaction. In this article, we are going to learn how does this tax work, which are the exact percentages to be paid, and how can you benefit from the existing bonifications and exemptions. Are you ready?
Key takeaways
- What it is: the tax on the profit when you sell an asset such as a property, land, shares or funds, paid through IRPF if you are resident or IRNR if not.
- Resident rates: 19% up to €6,000, 21% up to €50,000, 23% up to €200,000, 27% up to €300,000 and 30% above that, applied band by band to the gain.
- Non-residents: a flat 19% on capital gains, whatever their nationality; when they sell a property, the buyer withholds 3% of the price and pays it with Modelo 211.
- Main home: residents who reinvest the proceeds in a new main home within two years pay no tax; residents of EU or EEA countries can also use this exemption.
- Over 65: residents aged 65 or over pay no tax on selling their main home, and other gains reinvested in a life annuity are exempt up to €240,000.
- How to calculate: the gain is the sale price minus selling costs, less the purchase price plus purchase costs, taxes and documented improvements.
Free live webinar · Thu 3 Dec · 17:00 CET
Taxes in Spain for expats, made clear
Tax residency, income tax, the Beckham Law and Model 720, with Cristian Balcells and tax accountant Pau Pascual. 45 minutes with live Q&A, in English, online.
What is Capital Gains Tax in Spain?
The capital gains tax is the tax that is paid on the profits that you obtain once you sell any kind of asset like a property or land, or shares, funds or other investments. Whenever the sale value is greater than the acquisition value (what you paid plus the costs and taxes of buying), capital gains tax will be paid on that difference, the profit.
So we are talking about one of the main taxes when selling your house in Spain.
Unlike some countries like in the UK in which this tax works independently, in Spain we find it integrated within the personal income tax (IRPF) for residents, and within the non-resident income tax (IRNR) for non-residents.
Let’s use an example in order to better explain how this tax works.
Imagine that you bought a property in Spain for €500,000. Now, after several years, you are planning to sell it. You find a buyer, and after some negotiations, you both accept that the sale price will be €700,000, as the Spanish real estate market has grown and properties are more expensive now. The resulting €200,000 that you earn is the taxable amount to which you will apply the capital gains tax rates (in practice the gain will be lower, because purchase and sale costs can be deducted).
As a Spanish tax resident you would pay €44,880; as a non-resident, €38,000. Here is why.
Capital Gains Tax rates in Spain for 2026
Capital Gains Tax rates for Spanish residents
Just as a reminder, you will be considered a tax resident in Spain if you stay in the country for more than 183 days per year (6 months), or if your main centre of business or economic interests is in Spain. You are also presumed to be resident if your spouse (not legally separated) and dependent minor children live in Spain. If another country also considers you resident, the double tax treaty between both countries decides.
In that sense, if you are considered a resident, the capital gains tax in Spain to be paid is calculated by bands, together with your other savings income (interest, dividends):
- 19% for the first 6.000€ obtained as a profit
- From 6.000€ to 50.000€, the tax percentage is 21%
- From 50.000€ to 200.000€, a 23%
- From 200.000€ to 300.000€, a 27%
- Over 300.000€, a 30% (since 1 January 2025)
Only the part of the gain that falls within each band is taxed at that band’s rate. The Basque Country and Navarre apply their own scales.
Remember that these rates will be applied to the difference between the acquisition value of the property (or any other asset) and its sale value, both adjusted for costs (see the calculator section below).
Do you have any doubts so far? Ask our lawyers anything (or continue reading for more information):
Capital gains tax in Spain for non-residents
So far we have seen the situation for those staying in the country for more than 183 days per year. But what happens to the non-resident taxpayers in Spain with regard to this tax?
Non-residents pay a flat 19% on capital gains from selling assets located in Spain, whatever their nationality or country of residence. The 24% rate you may read elsewhere applies to other income of non-EU/EEA residents, such as rental income, not to capital gains. Going back to our example, a non-resident would pay €38,000 on the €200,000 gain, less than a resident.
Are there any reductions or exemptions for non-residents?
The answer is yes, but very few.
If you live in another EU or EEA country with effective exchange of tax information (including Iceland, Norway and Liechtenstein) and sell what your main home in Spain was, the gain is exempt if you reinvest the proceeds in a new main home within two years. You can apply the exemption in Modelo 210 or, if you reinvest later, claim back the 3% withheld with Modelo 228.
Non-residents cannot use the over-65 exemption, and residents of non-EU/EEA countries (including the UK and the US) cannot use the reinvestment exemption either. The pre-1995 reduction coefficients, on the other hand, do apply to non-residents.
Capital Gains Tax when selling property in Spain
Selling a property in Spain can involve three different obligations: capital gains tax on the profit, the 3% withholding if the seller is a non-resident, and the plusvalía municipal charged by the town hall.
The 3% withholding for non-resident sellers (Modelo 211 and Modelo 210)
When the seller is a non-resident, the buyer must withhold 3% of the agreed price, not of the gain, and pay it to the Spanish Tax Agency with Modelo 211 within one month of the sale. This is an advance payment on the seller’s tax, not the final tax. The seller then files Modelo 210 within the following three months to declare the actual gain and either pay the balance or claim a refund of the excess.
In our example, the buyer would withhold €21,000 (3% of €700,000). With a tax bill of €38,000, the seller would still have to pay €17,000. If you sell with no gain or at a loss, filing Modelo 210 is how you get the 3% back.
Plusvalía municipal: the local tax on property sales
Besides capital gains tax, the town hall charges the plusvalía municipal (IIVTNU) on the increase in value of the urban land. It applies to residents and non-residents alike and is normally paid by the seller. You can choose between an objective calculation, based on the cadastral value, and one based on the real gain, whichever is lower. If there was no real increase in value, no tax is due. The plusvalía you pay can be deducted when calculating your capital gain.
Costs you can deduct when selling a property
- Purchase costs (added to the acquisition value): transfer tax (ITP) or VAT and stamp duty, notary, land registry and legal fees.
- Improvements with invoices (added to the acquisition value). Routine maintenance and repairs do not count.
- Sale costs (subtracted from the sale price): estate agent’s commission, notary and legal fees paid by the seller, and the plusvalía municipal.
If you rented the property out while you were resident, the depreciation you deducted reduces the acquisition value.
Capital Gains Tax exemptions and reductions in Spain
If you are wondering how to avoid capital gains tax in Spain, these are the legal options. There are several ways to reduce or eliminate it, most of them only available to Spanish tax residents. Let’s go over them briefly.
1. The main home reinvestment exemption
If you are a Spanish tax resident and the amount of money that you earn from the sale of your main home is reinvested into the purchase of a new one within two years before or after the sale, and you will use this new house or flat as your new home, you don’t need to pay capital gains tax. If you reinvest only part of the money, only the proportional part of the gain is exempt.
This is what we call the main home exemption.
Hence, what you need to consider here is that the property you are selling was your habitual residence, and the one you are acquiring will be too. As a rule, a home counts as your habitual residence when you have lived in it continuously for at least three years.
You must declare the sale and the exemption in your income tax return for the year of the sale.
2. Capital gains tax in Spain over 65 years
If you are a Spanish tax resident aged 65 years old or over and sell your main home, it does not matter if the amount of money you get will be reinvested or not. You won’t need to pay this tax.
Nevertheless, you must bear in mind that there is a crucial condition you must meet in order to benefit from the 65-year-old exemption. And that is that the property you are selling must be your habitual residence. In other words, a minimum of 3 years lived in the property before selling it is required in order to avoid paying capital gains tax, and it must still be your main home when you sell it or have been so within the previous two years. This exemption does not cover second homes or other assets, and it is not available to non-residents.
Over 65: reinvesting in a life annuity
If you are 65 or over and sell any other asset, a second home, shares or funds, the gain is exempt if you reinvest the proceeds, up to a maximum of €240,000, in a life annuity (renta vitalicia) for yourself within six months. If you reinvest less, the exemption is proportional.
3. Reduction on assets bought before 1995
If you bought the property you now want to sell before 1995, part of your gain can be reduced with the so-called reduction coefficients (coeficientes de abatimiento).
This means that all the properties and other assets that were acquired until 31 December 1994 are eligible for this reduction. Nevertheless, there are two things to consider:
- The reduction only applies to the gains generated up to 19 January 2006. Any increase in the asset value afterwards won’t include the tax reduction and will be taxed at the normal rate.
- Since 2015, it only applies while the combined sale value of all the assets you sell using it does not exceed €400,000 per person
Then, if the property or asset you want to sell meets these requirements, which is the exact reduction you will enjoy? 11.11% per year for properties, 25% per year for listed shares and 14.28% per year for all other assets, for each year of ownership beyond two, counted up to 31 December 1996.
What if you sell at a loss?
Spanish residents can offset a capital loss against other gains in the savings base and carry any remaining loss forward for four years. Non-residents cannot carry losses forward, but they should still file Modelo 210 to recover the 3% withheld.
What assets are subject to Capital Gains Tax?
As we have previously mentioned, properties are not the only assets subject to the capital gains tax.
This tax applies mainly to:
- Company shares and investment funds
- Buildings
- Lands
- Flats and houses
- Cryptoassets
- Precious metals, art and other valuables.
Selling or redeeming bonds produces investment income rather than a capital gain, but it is taxed at the same 19%–30% savings rates.
Capital gains tax calculator Spain
Would you like to easily compute your capital gains tax in Spain?
Then follow these four steps:
- Sale value = sale price − costs of selling (estate agent, notary and legal fees, plusvalía municipal).
- Acquisition value = purchase price + purchase costs and taxes + documented improvements.
- Gain = sale value − acquisition value.
- Tax = the progressive bands if you are resident, or 19% if you are a non-resident.
Worked example
| Item | Amount |
|---|---|
| Purchase price | €300,000 |
| Purchase costs and taxes | €30,000 |
| Documented improvements | €20,000 |
| Acquisition value | €350,000 |
| Sale price | €500,000 |
| Selling costs | €20,000 |
| Sale value | €480,000 |
| Taxable gain | €130,000 |
| Tax as a Spanish resident | €28,780 |
| Tax as a non-resident (19%) | €24,700 |
As a resident: €1,140 (19% of the first €6,000) + €9,240 (21% of the next €44,000) + €18,400 (23% of the remaining €80,000) = €28,780. As a non-resident, the buyer withholds €15,000 (3% of €500,000), so the seller pays the €9,700 balance with Modelo 210.
Every sale is different: your residency, an inherited property, a rented property or the Beckham Law can change the final bill. Our tax team can review your case and file your Modelo 210 before you sign.
FAQs about Capital Gains Tax in Spain
How much Capital Gains Tax do non-residents pay in Spain?
Non-residents pay a flat 19% on the gain, whatever their nationality. When they sell a property, the buyer withholds 3% of the price as an advance payment, and the seller settles the difference or claims a refund with Modelo 210.
Is plusvalía municipal the same as Capital Gains Tax?
No. Capital gains tax is a state tax on your whole profit, paid through IRPF (residents) or IRNR (non-residents). The plusvalía municipal is a separate local tax on the increase in value of the urban land, charged by the town hall. When you sell a property you may have to pay both, but the plusvalía you pay reduces your capital gain.
Let us optimize your taxes!
Now you know the rules of the game. Nevertheless, you may still find it difficult to solve the puzzle.
There are several rules and exemptions regarding all the taxes you need to pay in Spain as an expat, and knowing them all can be nearly impossible. That is why we want to make your life easier.
Our tax lawyers are specialized on expat taxes. They will analyze your situation, answer all your doubts and manage all your taxes so you can pay just what you should.
We want you to focus on enjoying your life in Spain without the need to worry about the boring part. Let us do that for you!
Choose the date that suits you best for a consultation with our lawyers, and let us guide you step by step.
Related content of interest:
Hello!
We are a swedish couple that have sold our property in Alfaz del Pi (Alicante), 24/05/2019
We bought a new property in the same region 24/04/2018.
We are not resident.
Regarding capital gains tax.
In your description, on this site, it seems like we can do “the main home exemption”!?
But other lawyers we have asked, says No!
“If the amount of money that you earn from the sale of the property will be reinvested into the purchase of a new one, and you will use this new house or flat as your new home, you don’t need to pay capital gains tax
That simple. This is what we call the main home exemption.
“Non-residents can enjoy a capital gains tax exemption provided that they are legally living in any other European Union country that has a tax agreement with Spain. If that condition holds, they will be able to also enjoy the main home exemption too”
Hi Sara!
Yes, in that case you will be allowed to benefit from the main home exemption.
For any other doubt do not hesitate to contact us at info@balcellsgroup.com!
Hello,
My husband and I have been resident in Spain since February 2018. We have just sold our London flat (which was our main home till then) and we now intend to buy in Spain, as currently we’re renting. However we want time to look around and I understand we have up to 2 years to invest in another home here, is that correct? And if so, do we need to put the proceeds of the sale on the Modelo 720? We don’t want to pay too much tax! Thank you
Hi Amanda,
As your case is really specific one of our economist would have to sit down and analyze it carefully with you. That is why we would really appreciate if you could send us an email at info@balcellsgroup.com so we can ask you the questions that would lead to the answers you are looking for.
Thanks a lot!
Hi,I sold my main residence in UK in September2018,I moved to Spain in same month,became resident in march 2019,I invested the money in 2 properties,1 my main residence,do I have to pay capital gains tax on the sale of my UK home,thxs
In order to assess what would be your best option, it would be ideal to have a consultation with you so that one of the lawyers can advise you taking into account your case. You can send an email to info@balcellsgroup.com
We have been resident in Spain since October 2015 & rent out our home in UK. If we now sell that property will we be liable for capital gains tax as we are over 65. Other accounts say yes because we have not lived in the property for the last 3 years.
Hi Brenda,
Yes, they are right. The over 65-year exemption just applies in case that we are talking about your habitual residence, which is equal to those 3 minimum years that they told you. So you will need to pay capital gains tax provided that you sell the property.
For anything else you may need, we are here to help! 🙂
We are non resident UK citizens over 65 own only one property here in Spain.We have owned and lived in the property since 2005. If we sell are we liable for capital gains tax. We pay non residents taxes.
Hi Coral,
That will depend on the country in which you have your habitual residence: there may be an exemption provided that Spain has any convention with that country. For that, we would need to analyze your situation in more depth. Would you mind sending us an email at info@balcellsgroup.com?
Thanks a lot!
I recently became in Spain. I have some company shares in the UK, some of which are in an ISA (therefore not liable to UK CG tax). Would I have to pay Spanish CG tax on those shares if I sold them and made a capital gain? Thanks!
Hi Mike,
That will depend on whether you are a resident in the country or not. If you would like us to check it specifically, please send us an email at info@balcellsgroup.com providing a bit more details of your current situation.
Thanks a lot!
Due to ill health problems, bought a property in 2018 to live in and put our house of 16 years up for sale, we have just sold it 2019. My husband is 65 years old. Do we qualify for any exemptions on Capital Gains Tax. We changed our Padron in April this year before we sold does this make any difference? we have been residents for over 16 years.
Hi Mary,
As you can read in the article, as your husband is 65, he does not need to pay capital gains tax on the gains obtained.
How will Brexit affect the amount of tax I will have to pay when selling my apartment in Spain. Also if I am selling before three years and I am a non Spanish resident will I need to pay a higher rate of tax.
Can you also please deduct all the tax payable on an apartment selling at 230.000 euros for instance please?
Thank you!
Hi George,
Unfortunately, there is yet no certainty about what will happen after Brexit. The tax you will pay will depend on the amount you sell it for.
If you still have any doubt, do not hesitate to contact us so our tax lawyers can get in touch with you.
Kind regards!
We have been told that because we bought the new home before selling our home of 16 years that my husband would not qualify, as the new home becomes his habitual home.
In that case, we would really appreciate if you could send us an email at info@balcellsgroup.com so the specialized tax lawyer can carefully analyze your situation and give you an answer, as we will need to check it in more depth. Thanks!
Hi,
My question is we have been Spanish resident since 2013
We own a property in uk planing to sell ,we purchased it
February 1986 for £50000 now selling it for £500000
what is the capital gains tax implication ,thank you
(I am over 65)
Send us an email at info@balcellsgroup.com and our accountant will help you out! 🙂
Hi,
I inherited a 1/4 part of my grandfather´s house in Ireland.
It was valued in total at 300,000 euros
I declared my part using modelo 720. Last year we sold the house at a price lower than the original valuation (140,000)
Do I need to declare this in my declaración de la renta?
Will I be paying capital gains on this?
Is there any other form I need to complete other than the declaracion…Thanks!!
Send us an email at info@balcellsgroup.com with all that info and one of our tax lawyers will get back to you with an answer as soon as possible! 🙂
Hi, we have sold our house in Spain at 152,000€ after fees. When we bought our home in 2005 we paid 85,000€. We did spend around 25K in modernisation etc, but on paper it shows we made a profit of 67,000€. We are in the process of buying a house at 101,000€ in Spain. We have been told the CG tax is paid on the amount we are NOT investing from our total sale price, eg 51,000€. Is this correct as we have invested more than the 67,000€ profit as the house is costing us 101,000€?
I am a tax resident in Spain. Do gains in accounts that were considered tax free in other countries when I lived there, e.g. premium bonds and ISAs I hold in the UK or a tax free savings account I have in Canada need to be declared in Spain? ie do they lose their tax free status now I am resident here? Thanks, Andrew
In order to assess what would be your best option, it would be ideal to have a consultation with you so that one of the lawyers can advise you taking into account your case. You can send an email to info@balcellsgroup.com
Hello, I have just read your article and am unsure as to our situation. We bought our UK house over 25 years and lived in it for several years but now live in Spain where we are resident. We wish to sell our UK house in order to buy a house in Spain. We are currently living on a plot of land in the countryside. We consider our UK house to be our principle property but will the tax authorities here in Spain see it that way?
In order to assess what would be your best option, it would be ideal to have a consultation with you so that one of the lawyers can advise you taking into account your case. You can send an email to info@balcellsgroup.com