Repetition. Ride to work every day.
For me, my hilly route is optional. But if I don't do it regularly, hit gets harder and I get slower. I try to do it at least twice a week--once with full panniers--except when I'm training for hilly rides, then I ride it every day. That's when I get good at hills, and faster on them.