Whenever you spend a significant amount of time logged out, in or on top of an inn, or in a major city, it sets you as rested. When you are rested, you get additional exp from kills. Usually, it only lasts one kill, but with enough time "resting", it can last longer.