Carry keys in your dominant hand splayed between your fingers.
Walk confidently, with purpose and with awareness of everything around you.
No headphones
If walking alongside overgrown hedges etc. keep as far from them as you safely can.
If you think you're being followed, head for the nearest shop/pub and wait there for a lift.
Always wear trainers for doing this walk.
Bag needs to be rucksack or cross body so that you're hands free.
Never walk home drunk.
I've walked around London, Hull, smaller towns in the NE and SE and along country roads at all hours in this fashion and rarely had an issue. I have been followed twice but headed into a shop both times and told the staff why.
I think something that might have helped is that from a distance, often it's probably not that obvious that I'm female because I walk fast and wear trainers. Obviously we shouldn't have to consider how we dress but if it's obvious from a mile off that you're a female, staggering along slowly in heels, carrying a little handbag in one hand etc. a predator is more likely to spot you.