Putting hot food into a cold right-from-the-cupboard thermos just uses the heat from the food to heat the thermos and usually means a lukewarm (if not cold) lunch.
To keep your thermos warm and your hot lunch hot carefully fill your thermos with boiling water, attach the lid and let sit for 5-7 minutes or longer. Drain the water, quickly wipe dry (unless you're putting a liquid in the thermos) and immediately place hot food into the thermos.
Bonus: This is also a great way to test how hot your thermos stays during the day. Simply fill with boiling water or hot water from the tap and leave for a few hours or the entire day. When you come home guage how hot your water is. If it's cold it may be time for a new thermos!
PS: Looking for things to fill your thermos with? Check out my Canned Soup Mom Best Leftovers to Lunchbox Favourites Recipes.