Free tool · Moving abroad

Tax residency day counter: have you passed 183 days?

By · Updated

In short

Add the dates you spent in Spain, the UAE, Portugal or the United States and the counter applies each country’s day test. Spain treats you as resident if you spend more than 183 days there in a calendar year. The UAE counts 183 days in any 12 months, or 90 days if you also hold UAE residence and have a home or job there. Portugal counts more than 183 nights in any 12 months that start or end in the year. The United States uses a weighted three-year test. Days are not the only rule: Spain, the UAE and Portugal can also make you resident through your home, family or economic interests, whatever the count.

The counter

Calculator by Borja Burguillos · open the full version on borbur.net ↗

Key facts

Spain
More than 183 days in the calendar year; any day of presence counts in full
UAE
183 days in any 12 months, or 90 days with UAE residence plus a home or job there; part days count
Portugal
More than 183 days in any 12 months starting or ending in the year; only days that include a night count
United States
31 days in the year and 183 weighted days over three years (this year, a third of last year, a sixth of the year before)
Other ways to be resident
Spain: centre of economic interests or family; UAE: usual home and centre of interests; Portugal: a home kept as habitual residence
Two countries at once
The tax treaty between them decides which one wins

How it works

1. Add your trips

Choose the country and the dates you arrived and left. Add as many trips as you need, up to 40, including the two previous years if the United States matters to you.

2. Each country’s rule

Spain counts days in the calendar year; the UAE and Portugal look at any 12-month period; the United States weights three years.

3. Read the result

You see the days each country counts, whether its day test is met and, for Spain, how many days you have left this year.

The rules it follows

Spain (article 9 of the income tax law): you are resident if you spend more than 183 days in Spain in a calendar year. Following the Central Economic-Administrative Court, a day of certified presence counts in full with no minimum hours, days between two certified stays can be presumed, and sporadic absences are added unless you prove tax residence elsewhere. The counter counts every day of each trip you enter, including the days you arrive and leave.

UAE (Cabinet Decision 85 of 2022 and Ministerial Decision 27 of 2023): resident if present for 183 days or more in a consecutive 12-month period, or 90 days or more if you are a UAE national, hold UAE residence or are a GCC national and also have a permanent place of residence or a job or business in the UAE. Any part of a day counts. The counter shows the busiest 12-month period that starts or ends in the year you choose.

Portugal (article 16 of the IRS code): resident if present for more than 183 days, consecutive or not, in any 12-month period starting or ending in the year, where a day counts only if it includes a night in Portugal. United States: the substantial presence test needs 31 days in the year and 183 days counting all of this year, a third of last year and a sixth of the year before; any part of a day counts. Exceptions such as transit, commuters from Canada or Mexico and exempt visa holders are not applied.

Moving between Spain and the UAE? Go deeper: Beckham Law calculator · Take-home pay by country · How pay works in the UAE

Go deeper in the book

Embed this calculator

Free to use on your website or blog. Copy the code below and paste it into your page’s HTML. Please keep the credit link.

Questions

How many days can I spend in Spain without becoming tax resident?

Up to 183 days in a calendar year by the day test. Spain can still treat you as resident if your main economic interests are in Spain or your spouse and minor children live there.

Do the days I arrive and leave count?

In Spain, the UAE and the United States, yes: any part of a day counts. In Portugal only days that include a night there count, so the day you leave does not.

Is the Spanish 183-day count per calendar year or any 12 months?

Per calendar year, from 1 January to 31 December. The UAE and Portugal look at any 12-month period instead.

How many days do I need in the UAE for a tax residency certificate?

183 days in a consecutive 12-month period, or 90 days if you hold UAE residence and have a permanent home or a job or business in the UAE. You can also qualify through your usual home and centre of interests.

What if two countries both say I am resident?

The tax treaty between them decides, usually by where you have a permanent home, then where your personal and economic ties are closest. Spain and the UAE have a tax treaty.

Does the counter store my trips?

No. Everything runs in your browser. The dates only appear in the page address if you copy the link to share your result.

Sources

  1. Agencia Tributaria, Manual práctico IRPF 2025: residencia habitual en territorio español (art. 9 Ley 35/2006)
  2. Agencia Tributaria, TEAC defines how days of stay in Spain are counted (June 2023)
  3. EY, UAE issues additional guidance on determination of tax residency for individuals (Cabinet Decision 85 of 2022, Ministerial Decision 27 of 2023)
  4. Portal das Finanças, Código do IRS, artigo 16.º (Residência)
  5. IRS, Substantial presence test
  6. IRS, Topic 851: Resident and nonresident aliens

Updated:

Free tools

Calculators built on the official rules, with their sources. Free, no sign-up.

See all free tools →

More books

Guides

How pay works in the UAE: basic salary, allowances and gratuityBasic salary, allowances, gratuity, no income tax: what a UAE pay package really means.Spain vs Dubai salary 2026: what you keep, and the Spanish salary that matches DubaiWhat the same salary leaves in Spain and in Dubai, and the Spanish salary that matches a Dubai one.Take-home pay index 2026: how much of your salary you keep in nine countriesHow much of a $40,000 to $250,000 salary you keep in nine countries, under 2026 rules.Can you be paid your salary in crypto or stablecoins?Can your salary be paid in crypto or stablecoins? The rules in the UAE and Spain.What is Bitcoin, and why does it exist?What it is, who made it, and why a money with fixed rules had to exist.What are stablecoins, and why do they matter?Digital dollars: how they hold their value, why they matter and the rules arriving.Money and pay: why money loses value and how pay is changingInflation, total rewards, pay transparency and what digital money changes for HR.Web3 and the business of sportFan tokens, crypto sponsorship and prediction markets: how money is changing sport.The best books to understand Bitcoin, for beginnersThe best books to understand Bitcoin, from first steps to the technical detail.The best books on stablecoinsThe best books and reports to understand stablecoins, from inclusion to regulation.Which banks are launching stablecoins, and what does it mean for you?Qivalis, Santander, BBVA, CaixaBank: which banks are launching stablecoins, and what it means for customers.Books on Web3 and sport: what to read firstThe few books worth reading on Web3, fan tokens and the business of sport, and what each one is for.Stablecoins in the UAE: what is allowed, who issues them and what it means for youWhat the UAE allows, who regulates it, and the first dirham stablecoins: AE Coin, DDSC and RAKBank.Open lists in Spain: how Spaniards vote today, and what would changeHow Spaniards vote for Congress and the Senate today, and what open lists would change.How does the D’Hondt method work? Spain’s seat formula, step by stepHow Spain turns votes into seats, with a worked example, and why the province matters more than the formula.How to vote from abroad in Spain’s 29 November 2026 electionHow Spaniards living abroad vote on 29 November 2026: the consulate urn, postal vote and deadlines.How many votes does a seat cost in Spain? Province by province, 29 November 2026How many voters stand behind each seat in Congress, province by province, for 29 November 2026.Postal vote for 29 November 2026: request it by 19 NovemberHow to vote by post from Spain on 29 November 2026: request by 19 November, send by 25 November.Polling station duty on 29 November 2026: pay, hours and time offCalled to sit on a polling station on 29 November 2026? Pay, hours, time off work and what to do if you cannot go.Can stablecoins make sending money home cheaper?Do stablecoins make sending money home cheaper? What the World Bank and IMF data show.Paying employees in stablecoins: what employers need to know in the UAE and SpainWhat employers in the UAE and Spain can and cannot do when they pay staff in stablecoins.How AI is changing the job market: what the major reports sayWhat the WEF, IMF, ILO, Stanford and PwC data say about AI, jobs and pay.Will Bitcoin be the money of AI agents? How machines pay, and what is still missingAI agents are starting to pay for things. Cards, stablecoins and Bitcoin compared as money for machines.Why does Bitcoin go up and down so much?Fixed supply, big funds, interest rates and leverage: why Bitcoin’s price swings so much.Bitcoin from zero: a free course in six short lessonsA free course in six short lessons: what Bitcoin is, transactions, wallets, safety, scams and tax in Spain.How a Bitcoin transaction works, step by stepWhat happens between pressing send and the payment being final: the queue, the fee, the block and the confirmations.What is a Bitcoin wallet? Keys, seed phrase and custodyA wallet does not hold coins: it holds keys. What the seed phrase is, and custody by an exchange versus your own.How to keep bitcoin safe: six habits for beginnersSix habits that protect bitcoin: the seed phrase on paper, never online, small tests, updates and a plan for your family.Bitcoin scams: the most common ones and how to spot themThe most common bitcoin scams, what they have in common, and how to check a platform before you send money.How bitcoin is taxed in Spain in 2026When bitcoin is taxed in Spain, the 19% to 30% scale, crypto-to-crypto swaps, FIFO and the Modelo 721.Token compensation explained: grants, vesting, lockups and taxHow token grants, vesting, cliffs and lockups work, how they differ from shares, and when they are taxed.Jobs in stablecoins and digital money: the roles, the skills and the talentThe roles stablecoins and tokenisation create in banks, issuers and corporates, the skills they need and where the talent comes from.Paid in a dollar stablecoin: who carries the exchange-rate risk?If part of the pay is a dollar stablecoin, who carries the exchange-rate risk: the employer or the employee? Four designs, with examples.Financial literacy at work: why digital money makes it HR’s jobOnly a third of adults reach the OECD’s minimum level of financial literacy. Why digital money makes it an HR question, and what a basic programme covers.
Portrait of Borja Burguillos

Borja Burguillos

Borja writes for people who want to understand money and incentives without the jargon. Born in Madrid and based in Dubai since 2012, he has advised companies on people and pay, built tech startups, and co-chairs the People & Organisation Committee at the Middle East Stablecoin Association.

WorldatWork Total Rewards and CAIA certified, CFA Investment Foundations, executive programmes at Wharton and IE Business School.