Hi,
Please have a look at the statutory residence tests below, and take the tests, to determine your residence position:
RDR3 Statutory Residence Test
If you are resident in the UK for the whole tax year, you will need to consider the split year treatment guidance. If split year treatment applies, you would only declare your worldwide income from the date you arrived in the UK until the end of the tax year. If split year treatment does not apply, you will need to declare your worldwide income for the whole tax year and claim a foreign tax credit of up to 100% of the foreign tax paid.
If you are considered to not be UK resident for the whole tax year, you would declare that you are not resident and only include any income and capital gains arising in the UK in a tax return.
Where you have to declare foreign income, and, or capital gains, where foreign tax is payable, you can claim a foreign tax credit in the foreign section of a tax return. You can see guidance on Self Assessment here:
Self Assessment
Thank you.