You calculate the taxable sales and multiply by the right VAT rate, and then deduct the input VAT on purchases to obtain the final figure that one owes to HMRC.