Yes, public liability insurance is tax deductible when calculating taxable profit, as an 'allowable expense' (an expense you can deduct when calculating taxable profit for your tax return). It is included in HMRC’s definition of allowable expenses.
When you buy your public liability insurance, be sure to keep your receipt and your policy documents safe so that you can show your tax calculations if your business is checked by HMRC. Also, if you have an accountant that does your tax return, you will need these documents to show them the cost of your cover so they can calculate it correctly and ensure your public liability insurance is tax deductible.