In the United Kingdom you are defined as a resident by the rules set out by the HMRC. In short, your residency is determined by your long-term intentions and the number of days you actually spend in the country. For the purpose of this exercise each day is counted if you are in the UK at midnight.
·    If you are in the UK and do not intend to stay for more than two years, you are a resident for the tax year if 183 or more days are spent in the UK.  If you spend less than 183 days in the UK, you will not be considered a resident for tax purposes.
If over the last four tax years you have spent 91 days or more on average per year in the UK, you will be considered a resident for tax purposes. You would be considered a resident for tax purposes from the date of your arrival if you intended to spend more than 91 days, on average per year, in the UK.
If you come to the UK and expect to stay for two years or more, you are considered a tax resident from the first day that you arrive.
There are also two types of residents: Ordinarily and not ordinarily.
Resident and ordinarily resident – When you come to the UK and expect to stay for three years or more. This can be proven by purchasing or leasing property available for three years or more.
Resident and not ordinarily resident – When you have been outside the UK and intend to come to the UK for at least two years, but less than three years.