Upvote:0
You will need to apply for a "Visitor in Transit visa"
Leaving the airport Apply for a Visitor in Transit visa if you’ll be going through UK border control but leaving the UK within 48 hours.
You can also apply for a long-term Visitor in Transit visa if you can prove you need to frequently pass through the UK over a longer period.
Fees Direct Airside Transit visa (DATV) - £32 Visitor in Transit visa - £59
please refer to the following link and note the cost may vary (still that is mentioned on the uk gov website)