If you have already paid VAT to HMRC but have not received the payment from the customer, you can reclaim it back.
When you write off a transaction the entire (tax+taxable) amount will be debited to Bad Debt.
You can raise a journal entry for the same as follows -
The number “20” is an example for an amount that you wish to reclaim.
This will debit input VAT, and you will be able to reclaim this from HMRC.
and GST filing.