The best way to avoid glare at night from oncoming vehicles is to:

To avoid being blinded by the lights of oncoming vehicles, you can glance to the right side of the road until the vehicle has passed.
DMV Writen Test Logo