That’s an option, but you need to think it through carefully. After all, you still need to ensure that you have sufficient income after retirement, and a capital withdrawal will reduce the future pension you receive from your pension fund.
You also need to weigh up the tax implications, so it is certainly advisable to talk to a tax consultant. For example, if by paying off the mortgage the future imputed rental value is higher than the mortgage interest, the difference is taxable as income.