An Ichneumon Wasp.
Also known as Ichneumon flies these are relatives of the Bees and Wasps. I haven’t seen this species before. Unfortunately I cannot identify it as there is no comprehensive guide to British Ichneumons. This species has a distinctive hind leg.