Check the bulb with a multi-meter for continuity, if it is good start looking for bad wires or corrosion in the light base it plugs into. I pull all my plug connections apart every year and spray contact cleaner in them and add a drop of oxyguard (electrial grease) in each fitting b-4 putting back together. You will never have a bad connection again that way.
2003 Yamaha RX-1 1000
2000 Polaris 700 XC 45th Anniversary Edition
1997 Polaris Indy 500 Sport
1998 Polaris Indy 500
1996 A Cat panther dlx 440