It's normally a symptom of the alternator going out. Before mine finally died a final death I was able to twice make the lights go away by disconnecting the battery and briefly touching the cables together (not the battery terminals!!!!). I have no idea why this worked, but it was suggested to me long ago by a benefactor on this forum (whose name I've forgotten
).
Note that if you have a big capacitor with an aftermarket stereo this is not something to try unless you just like scaring the bejesus out of yourself with sparks. etc.