Things may well have changed since, but when I took out a 10 year BTL fixed rate in 2019, the early repayment penalties were something like 7% - 5% for the first 5 years and then just 1% from year 5 onwards, so not really an obstacle from year 5 on (particularly if you factor in the fees for otherwise moving deals every 2-3 years).
In addition, most fixed rates provide the ability to repay 10% each year without penalty.
That said, the rate at the time was 2.75% so a no-brainer in my view. Would I fix for 10 years today if the rate was 5+%, probably not - or probably not on all of the borrowing. Would I fix for 10 years today if the rate were 4% - yes I probably would, but again, possibly not on all of it.