A ballast is an electrical device used to control the current in an electrical circuit. A lighting ballast controls the start-up and regulation of fluorescent and high intensity discharge (HID) lamps.
A ballast is necessary for fluorescent and HID lamps because they have a negative resistance, which means if they are connected to a constant voltage source they will continue to draw more current until something melts down. The ballast controls the current and keeps everything working correctly.
Ballasts come in many varieties and complexities, from a simple resisters to computer-controlled units.