On my way out to Nairobi from the U.S., I had 8 hours in the Istanbul airport. I landed after dark and took off when it was still dark, so it was just 8 hours... hanging out... by myself.
And on our way back to the United States, we were supposed to have a disgusting 13 HOUR LAYOVER in Abu Dhabi. Amazingly, Layne was able to sweet talk his way into changing our tickets and getting on an earlier flight - completely free of charge. Don't ask me how he did it; the man could sell honey to the bees. But before we knew we would be saved from the drudgery, we came prepared for a long 13 hours of just waiting around. When you know you're in for a long layover, you have to prepare.
Do your research - Make sure you know what converters you may need if you plan on charging your devices. Find out what services are available at the airport you'll be laying over in. Abu Dhabi had spa services, restaurants, and sleeping pods. They usually have an airport hotel, but it was being renovated. Fortunately, the UAE offers free visitor visas to citizens of certain countries and - cha-ching! - the good ole U S of A is on that list. Our layover ended up being about six hours, and we were able to take advantage of our free visas and get out of the airport for a bit. It wasn't enough time to see much, but we hit a mall and were able to have Shake Shack, Starbucks, and Cinnabon. You know - just the essentials.
Have a game plan - Before we left Nairobi, Layne and I knew we'd spend a few hours out and about exploring Abu Dhabi. But we had 13 hours and it was going to go through the night. It was inevitable that we'd also be spending some time in the airport itself. This layover was just the beginning of our week of travel, and we were armed with hours of downloaded podcasts, music, books, TV shows, and movies. We'd even brought a deck of cards. I also had my fully-charged computer with pictures to edit and blog posts I could work on. We had our sleep aids, eye masks, and ear plugs. We figured we would hit the town for a few hours, head back to the airport and watch some shows for a bit, and then try to sleep before our flight. We knew we'd have dinner outside the airport, and grab breakfast the next morning inside the airport before our flight.
Don't forget to move - It's important to walk around on your layovers. Even if you're not leaving the airport, you need to get your blood pumping to avoid the potential of deep vein thrombosis. This is especially true if you're in between two long flights like we were (5 hours to Abu Dhabi, then 8 more hours to Paris). Explore the airport gift shops, and check out the restaurants. Most airports have plenty of shops you can pop into, and the worst case scenario is plenty of long hallways you can stroll down and people watch.
Keep busy and remember that this, too, shall pass - In the end, it is what it is. Hours spent in a airport, not doing much of anything. Some airports may be worse to be stuck in than others, and even when you try to prepare you may not know until you get there. I would hate to be stuck in NBO for any length of time, but I could hang out in some airports for hours and not be too fussed about it. Come prepared with things to entertain yourself or to work on, and then just wait it out. Hopefully your long layover is worth it and brings you to an amazing final destination, be it somewhere or exotic or just a stop on your way home.