Back to blog
Digital Nomad Visa

Moving to Spain Mid-Year: Why Your Property Sale Can Still Be Taxed in Spain

HoplyWritten by Hoply
Natalia MenendezReviewed by Natalia Menendez, licensed lawyer expert
12 min read
Moving to Spain Mid-Year: Why Your Property Sale Can Still Be Taxed in Spain

Moving to Spain in the second half of the calendar year does not reliably keep you outside Spanish tax residency, and it does not protect a property you sold before you arrived. Under Article 9.1.a of Law 35/2006 (LIRPF), you become a Spanish tax resident if you spend more than 183 days in Spanish territory during the calendar year. Spain's tax period is the full calendar year under Article 12 LIRPF, with no option to split it at your arrival date.

That means a home sold in March can fall inside the Spanish tax net if you cross the threshold by December, even though you were living and working abroad on the day of the sale. The practical cutoff is 2 July rather than 1 July, because 1 July to 31 December is 184 days, which is already more than 183.

If you are planning a Digital Nomad Visa move and a property sale in the same year, the order of those two dates can be worth tens of thousands of euros.

How Spain's 183-Day Tax Residency Rule Actually Works

Article 9.1.a LIRPF sets the day count test in plain terms: more than 183 days in Spanish territory during the calendar year. There is no multi-year averaging formula of the kind used by other countries. Each calendar year is counted on its own.

Two details make the count stricter than most applicants assume.

First, sporadic absences are added to your Spanish day count unless you can prove tax residency in another country. A tax residency certificate from that country is the evidence the Agencia Tributaria expects. Without it, a month back home does not subtract from your Spanish total.

Second, the Tribunal Económico-Administrativo Central, in resolutions of 28 March 2023 and 25 April 2023, has consolidated a strictly physical criterion. A day counts if you were present in Spanish territory at any point during it, with no overnight stay required and no minimum number of hours. Your arrival day and your departure day both count as full days.

This is a different rule from the 183-day figure that appears in immigration debates about absences from Spain during a residence permit. Those two thresholds are frequently confused, and we cover the immigration side separately in our analysis of what Spain's Supreme Court ruling on the 183-day rule actually covers. Tax residency and permit validity are governed by different bodies of law and different authorities.

Why a Mid-Year Move Does Not Automatically Keep You Outside Spanish Tax Residency

The arithmetic is the part most applicants get wrong. Arriving "around the middle of the year" is not a safe position, because the second half of the year is slightly longer than the first.

Arrival date in SpainDays remaining to 31 DecemberTax resident on day count alone?
1 June214Yes
1 July184Yes
2 July183No
1 August153No
1 October92No

An arrival on 1 July already places you at 184 days, one day over the threshold.

The table also assumes you set foot in Spain for the first time on that date, which is rarely true. A scouting trip in February, a week viewing apartments in April and a family holiday in May all count toward the same annual total. Applicants who spent time in Spain earlier in the year while researching the move regularly discover that their "clean" October arrival is not clean at all.

None of this means a late arrival is a strategy. It means the count has to be modelled against your actual travel history rather than estimated, and that the day count is only the first of several tests.

Spanish Tax Residency Covers the Full Calendar Year, Not Just From Your Arrival Date

Spanish law does not allow the tax year to be split when residency changes. Article 12 LIRPF fixes the tax period as the calendar year, and the Agencia Tributaria confirms in its own guidance that individual tax residency is determined by complete calendar years, regardless of when during the year the change of residence takes place. Where a change is recognised, its effective date is 1 January of that same year.

This is not a retroactive application of the law, and it is worth being precise about the distinction. Nothing is being reached backward for. The tax period always ran from 1 January to 31 December. What happens on 31 December is simply that the criterion is confirmed, and the whole period is then settled on that basis.

The practical consequence is the same either way. If you become a Spanish tax resident for a given year, every item of worldwide income you received in that year is within scope, including income received in January while you were still living abroad, still working for a foreign employer and had never set foot in Spain.

Why Selling Your Home Before You Move Does Not Put the Sale Out of Reach

Spanish tax residents are taxed on worldwide income. A capital gain on the sale of a property located abroad is worldwide income, and it is allocated to the savings tax base.

The savings scale for 2026 is uniform across common territory Spain, with no regional component:

GainRate
Up to €6,00019%
€6,000 to €50,00021%
€50,000 to €200,00023%
€200,000 to €300,00027%
Above €300,00030%

The top bracket rose from 28% to 30% under Law 7/2024, with effect from the 2025 tax year. Any table still showing 28% at the top is out of date.

So the belief that a sale completed before physical relocation is automatically beyond Spain's reach does not hold. What determines the outcome is not where you were standing on the day of the sale. It is whether you end up a Spanish tax resident for the calendar year in which the sale took place.

Worked Example: Arrival Date, Sale Date and the Tax Outcome

Consider a remote employee based in Dubai who sells her apartment there on 15 March 2026, realising a gain of €120,000, and then relocates to Spain under the Digital Nomad Visa.

If she arrives on 20 June 2026, she spends 195 days in Spain that year. She crosses the threshold, becomes a Spanish tax resident for the whole of 2026, and the March gain enters her Spanish savings base. Applying the 2026 scale, the Spanish tax on that gain comes to roughly €26,480.

If she arrives on 10 July 2026 instead, she spends 175 days in Spain. On the day count alone she is not a Spanish tax resident for 2026, and the March gain sits outside Spanish taxation for that year.

The gap between those two dates is twenty days. The gap between the two tax outcomes is around €26,480.

The United Arab Emirates levies no personal capital gains tax on individuals, which removes the usual safety net. Double taxation relief works by crediting tax already paid abroad, so where no foreign tax was paid there is nothing to credit and Spain taxes the full gain. Applicants relocating from the Gulf are structurally more exposed here than applicants coming from higher-tax jurisdictions, a pattern that also shows up in how a Gulf-based employer changes the Digital Nomad Visa route itself.

The Residency Triggers That Have Nothing to Do With Counting Days

Article 9.1 LIRPF contains two further tests, and either one is sufficient on its own.

The first is the centre of economic interests, under Article 9.1.b. If the main base of your activities or economic interests sits in Spain, you can be treated as resident regardless of your day count. Administrative and judicial practice applies this qualitatively, assessing the overall structure of your economic life rather than running a simple comparison of asset values.

The second, under Article 9.1.c, is a presumption based on family. If your spouse and dependent minor children habitually reside in Spain, you are presumed resident unless you prove otherwise. Families who send one parent and the children ahead while the other finalises a property sale abroad should look at this carefully.

These tests matter because they cannot be managed with a calendar. They also matter because the Agencia Tributaria now cross-checks tax and contribution data far more frequently than it once did, a shift we examined in detail in our review of what actually changed in tax and Social Security enforcement.

What Can Reduce or Remove the Spanish Tax on the Sale

Three routes are worth assessing before you conclude that a gain is lost to Spanish tax.

The special regime for inbound workers under Article 93 LIRPF, widely known as the Beckham Law, is the most powerful. Taxpayers who validly opt in are taxed under non-resident rules and, as the Agencia Tributaria confirms, are subject to Spanish tax only on income from Spanish sources. A capital gain on a property located outside Spain therefore falls outside Spanish taxation while the regime applies. Access is conditional: you must not have been a Spanish tax resident in the previous five years, and Form 149 must be filed within six months of your Social Security registration. Our guide to the Beckham Law for digital nomads sets out the eligibility conditions in full.

The reinvestment relief for a main home, under Article 38 LIRPF and Articles 41 and 41 bis of the IRPF Regulation, is the second route and it is more widely available than most applicants realise. In binding ruling V1860-25 of 14 October 2025, the Dirección General de Tributos confirmed that a gain on the sale of a main home located abroad, in that case in California, can be exempt where the taxpayer is a Spanish tax resident and reinvests the full proceeds in a new main home within two years. The location of the property sold does not block the relief. Earlier ruling V2910-21 of 18 November 2021 confirms that this holds even where Spanish tax residency was acquired during the tax year in question. Both properties must meet the habitual residence conditions, which generally require three years of continuous occupation.

The third route is the applicable double taxation treaty, and it is the weakest. Spain has a treaty with the United Arab Emirates, signed in Abu Dhabi on 5 March 2006 and published in the BOE on 23 January 2007, whose Article 13 addresses capital gains on immovable property. Treaties prevent the same gain being taxed twice, but they do not create an exemption where no foreign tax was charged in the first place. Note also that taxpayers under the Article 93 regime are not treated as Spanish residents for treaty purposes, which changes the analysis again. Because the interaction between these three routes turns entirely on your dates, your prior residence history and where the property sits, this is the point at which it is worth putting the specific numbers in front of Hoply's tax specialists in a consultation before anything is signed.

How to Sequence Your Move and Your Property Sale

Sequencing starts with an honest day count for the current year, including every short trip already taken, not just the planned relocation date. From there the question is whether the sale is better placed in a year when you are clearly non-resident in Spain, or inside a year covered by the Article 93 regime, since those are two different answers reached by two different mechanisms.

Where the property is your main home and you intend to buy in Spain, the reinvestment route often changes the calculation completely, and it can make an earlier arrival preferable rather than riskier. Where you cannot claim the property as a main home, the analysis usually turns on the Article 93 regime and on whether the timing conditions for filing Form 149 can realistically be met alongside your visa timeline.

Applicants filing from inside Spain face an additional layer, because the entry date, the application date and the residency count interact. We set out how that route works in our guide to applying from within Spain for three years plus Beckham Law.

The one approach that consistently fails is deciding the relocation date first and asking about the tax consequences afterwards.

Key Takeaways

  • Spanish tax residency is triggered by more than 183 days in Spanish territory during a calendar year, under Article 9.1.a LIRPF.
  • The real cutoff is 2 July, because 1 July to 31 December is 184 days.
  • Arrival and departure days both count in full, and short earlier trips count too.
  • Spanish tax residency applies to the full calendar year under Article 12 LIRPF, so income received before you arrived is within scope.
  • A foreign property sale in that year is taxed in the savings base at 19% to 30% for 2026.
  • The Beckham Law regime keeps foreign source gains outside Spanish tax, and reinvestment relief can exempt a main home sold abroad under DGT ruling V1860-25.
  • Day count is not the only trigger. Centre of economic interests and family presence can each establish residency on their own.

Getting Your Timing Reviewed Before You Commit

Move dates and sale dates are usually decided months apart, by different people, for reasons that have nothing to do with tax. That is precisely why the two so often collide. A twenty day difference in arrival date changed the outcome by more than €26,000 in the example above, and that example is not unusual.

If you are still deciding when to move and whether Spain is the right destination at all, the fastest way to see how your dates interact with the visa timeline is to book a free case evaluation with Hoply, where our Spain-based lawyers review your situation and flag the timing issues before they become irreversible.

Frequently Asked Questions

This article is for informational purposes only and does not constitute legal or tax advice. Regulations can change and every case is different. Always consult a qualified immigration lawyer and tax adviser. At Hoply we have specialists who can review your specific situation.