How to charge a car battery?

Maintaining the recommended level of charge of a car battery is advisable both for its longevity and for utility reasons – how best to charge the battery?