As suggested if you are a Swiss resident with a UK pension then you can get relief from the UK on this on the basis you are declaring this to the Swiss authorities. You will need to
complete the relevant DT form:
Digest of Double Taxation Treaties April 2018
Double Taxation: UK-Switzerland (Form Switzerland-Individual)
As a Swiss resident, the Swiss authorites have the right to tax this pension so to avoid double taxation it would be best to complete the above form. If however this is a government pension,
then this would remain taxable in the UK unless you are BOTH a resident AND national of Switzerland. Likewise conditions change if this were a lump sum. You need to chcek the double
taxation agreement with the type of pension you have.