Staying well hydrated is the most effective way to prevent a hangover- drinking plenty of water throughout the day, and avoiding excess amounts of caffeine, especially high octane energy drinks loaded with plenty of caffeine which lead to loss of water from your body.
FORBES: Five Ways To Avoid a New Year's Day Hangover