iPhone location journals

UK statutory residence test day counter

Turn a Country Days CSV or typed stays into UK days under the midnight rule and see every step, in your browser. A count, not tax advice.

Count your UK midnight days by tax year

This is a count, not tax advice. It applies the day-based parts of the UK Statutory Residence Test (SRT) to the dates you give it and does not say whether you are UK tax resident. Missing dates make the count too low, and tests that depend on work and homes are not calculated. For the official check, use HMRC’s Tax Residence Indicator (the residence status checker) and ask an adviser. Read what this tool does not do.

Counting for the US instead? Use the substantial presence test calculator or the citizenship physical presence calculator. For other countries and windows, use the days-in-country calculator.

Load a Whereday Country Days CSV, add stays by hand, or both. The page works out where you were at the end of each day, counts UK midnight days for the tax year you pick (6 April to 5 April), and shows each step. No account, upload or analytics.

What counts as a UK day: the midnight rule

For the SRT, a day counts as a day spent in the UK if you are present in the UK at the end of that day, which is midnight (Finance Act 2013, Sch. 45 para 22). Two things are left out even if you are in the UK at midnight, and both are marked by you in the tool:

Read the paragraph for the exact conditions before you mark a date. The tool cannot tell whether yours are met.

Two invented examples

That is why this result can differ from a “days present” count such as the one Whereday’s Country Days and the US test use. The 183-day rule explained compares them.

Travel days: how the end-of-day country is inferred

A Country Days CSV records which countries you were in on a date. It does not record where you were at midnight, so the tool applies a stated rule to each date:

  1. One country on the date: that country is the end-of-day country.
  2. Two or more countries: the end-of-day country is the one that also appears on the next date, if exactly one does. This is marked inferred.
  3. Anything else (no country on the next date matches, several match, or there is no next date): the date is unresolved. It is listed and you pick the end-of-day country, or “In transit / none”. A date you pick is marked picked by hand.

Every result shows how many dates were taken as one country, how many were inferred and how many you picked. Unresolved dates are not counted anywhere until you pick, and the page says so. The tool never assumes where you were at midnight. Note that a date with only one country is taken at face value even if you travelled that day, because the file holds nothing else.

How the SRT works, in order

HMRC’s guidance, RDR3, applies the tests in this order. The tool covers only the day-based parts.

1. Automatic overseas tests (RDR3 section 2)

2. Automatic UK tests (RDR3 section 3)

3. Sufficient ties (RDR3 section 4)

If no automatic test settles it, the number of UK ties you need depends on your days in the UK and on whether you were UK resident in one or more of the previous 3 tax years.

Ties needed (RDR3 section 4)
Days in the UK in the tax yearTable A: resident in 1 or more of the previous 3 yearsTable B: resident in none
16 to 45At least 4Automatic overseas test 2 (fewer than 46)
46 to 90At least 3All 4
91 to 120At least 2At least 3
121 to 182At least 1At least 2
183 or moreAutomatic UK test 1

Under 16 days in Table A is automatic overseas test 1. The tool shows “days left before the next band” for the tax year: the days you can add before the count reaches the next row.

The five ties

The deeming rule: qualifying days after the 30th

A qualifying day is a day on which you were in the UK at some point but not at the end of it. Under Sch. 45 para 23 the deeming rule applies only if you have at least 3 UK ties for the tax year, more than 30 qualifying days and were UK resident in at least one of the 3 previous tax years. When it applies, each qualifying day after the 30th, counting from 6 April, is treated as a day spent in the UK. Deemed days do not count towards the 90-day tie. HMRC explains it at RFIG20720.

The tool shows the midnight total and the total with deeming. It uses the second for the day tests only when the rule applies, and it uses the ties you have ticked and the ties it computed to decide that.

Synthetic example: resident last year, 3 ties
UK midnight days100
Qualifying days40
Deemed days (40 − 30)10
Days used for the tests110

With fewer than 3 ties, or if you were not resident in any of the 3 previous years, the same dates give 100 days.

Worked examples

Two invented people, both for the 2025–26 tax year (6 April 2025 to 5 April 2026). The tables are the calculator’s output; load the examples above to see the same figures, and a test checks every number.

A leaver (synthetic)

Resident in the UK in the previous years, moves to Spain in July 2025 and returns for two short visits. The file starts on 6 April 2024, so 2023–24 is not covered. They tick the accommodation tie only. Download the synthetic CSV.

Leaver, 2025–26
StepResult
UK midnight days118
Of those, inferred from the next date2
Of those, picked by hand0
Qualifying days3
Deemed days added0 (3 is not more than 30)
Days used for the tests118
UK midnight days 2024–25365
UK midnight days 2023–240 (not covered by the file)
Ties you have2: 90-day tie and accommodation tie
Ties needed (Table A, 91 to 120 days)2
Days left before the next band2 (the next band starts at 121)
Day tests point toSufficient ties test met

The country tie is not met: the UK has 118 end-of-day dates and Spain has 247.

An arriver (synthetic)

Not resident in any of the previous 3 years, lives in France, then spends the winter in the UK. The file starts on 6 April 2025, so the two previous years are not covered and nothing is typed. One date, 14 February 2026, has two countries and no record on the next date, so it is unresolved; the example picks the UK for it. They tick the family and accommodation ties. Download the synthetic CSV.

Arriver, 2025–26
StepResult
UK midnight days102
Of those, inferred from the next date1
Of those, picked by hand1
Qualifying days1
Deemed days added0 (not resident in a previous year)
Days used for the tests102
UK midnight days 2024–250 (not covered by the file)
UK midnight days 2023–240 (not covered by the file)
Ties you have2: family tie and accommodation tie
Ties needed (Table B, 91 to 120 days)3
Days left before the next band18 (the next band starts at 121)
Day tests point toSufficient ties test not met

Leave 14 February unpicked and the count is 101, with one unresolved date shown. Neither example says anything about the tests that are not calculated, which could change the answer.

What this tool does not do

For the official check, use HMRC’s Tax Residence Indicator, the residence status checker linked from GOV.UK. It asks you to type in a day count, which this page can work out from your dates. Then ask a qualified adviser. This page makes no statement about any person’s tax residence.

Where your dates come from

Export Country Days from Whereday: open Timeline, then Country Days, choose All time and tap Export. The CSV has the columns country_code and local_date, and this page reads it with the same rules and row checks as the days-in-country calculator: bad rows are listed with their line numbers, and a repeated country and date counts once.

Viewing Country Days and adding manual stays are free. From version 1.8, new users keep exports after tracking access expires; existing free users keep their previous export-unlock requirement. How Whereday records country days covers travel days, time zones and adding a missing stay.

Recorded days only cover the time the app was recording, so gaps make the count too low; add missing stays by hand. A country-date CSV is a summary, not a backup of your visits and points, so keep a restorable copy too. Everything happens in your browser. This page blocks network connections and includes no analytics.

Questions

Does the day I arrive count?

Yes, if you are in the UK at midnight at the end of it, unless the transit or exceptional-circumstances rule in para 22 applies.

Does a layover count?

Only if you are in the UK at midnight. If you arrive as a passenger one day, leave the next and do nothing substantially unrelated to passing through, para 22 leaves the day out; mark it as transit.

What if I was in the air at midnight?

Then you were not present in the UK at the end of that day, so it is not a UK midnight day. In a Country Days CSV, such a date with two countries may be unresolved; pick “In transit / none” or the country you reached.

Is this the same as the US 183-day test?

No. The US substantial presence test counts any part of a day and weights three years; see the substantial presence test calculator. The UK count here is midnight days in one tax year. The 183-day rule explained compares them.

Does this tell me my tax residence?

No. It counts days and applies the day-based tests only. Work and home tests, split year, temporary non-residence and treaties can all change the answer. Use HMRC’s Tax Residence Indicator and an adviser.

Keep the dates behind your UK day count.

Whereday records the countries you’re in and keeps the dates on your iPhone, and you can export Country Days as CSV whenever you need a count.

Download free for iPhone