President Barack Obama said on Tuesday former Libyan leader Muammar Gaddafi missed his chance to bring democracy to his country and described his death as a message to dictators around the world.

This is somebody who, for 40 years, has terrorized his country and supported terrorism, Obama said on NBC's Tonight Show with Jay Leno.

He had an opportunity during the Arab Spring to finally let loose of his grip on power and to peacefully transition into democracy.

We gave him ample opportunity, and he wouldn't do it.

Gaddafi was buried in a secret desert location on Tuesday, five days after he was captured, killed and put on grisly public display. The former leader was seen on video being mocked, beaten and abused before he died.

Obviously, you never like to see anybody come to the kind of end that he did, but I think it obviously sends a strong message around the world to dictators that ... people long to be free, Obama said.

NBC released excerpts of Obama's interview with Leno ahead of its broadcast later on Tuesday.

Obama is in the middle of a swing through western states including Nevada, California and Colorado, where he has mixed White House business with events for his 2012 re-election campaign.

Asked by Leno if he had watched the debates by his potential Republican rivals, Obama demurred.

I'm going to wait until everybody is voted off the island, he joked, to applause. Once they narrow it down to one or two, I'll start paying attention.