What you eat and drink before bed can affect your sleep. For example, foods containing the amino acid tryptophan—a building block of the sleep-related chemical serotonin—could help you sleep. Foods such as eggs, chicken, fish, and nuts contain tryptophan. Carbohydrates make tryptophan more available to the brain, so if you're eating a light snack before bed, you might try something like a few whole wheat crackers or cereal with milk. On the other hand, foods that upset your stomach, such as fatty, fried, or spicy foods, are best avoided before sleep.
Alcohol might make you drowsy and help you fall asleep, but it can actually make it harder to sleep deeply and continuously throughout the night and should be avoided in the hours before bed. As you know, caffeine is a stimulant and it's effect on the body lasts many hours, so it is best not to consume it after the mid-afternoon.
There are certain foods that could promote better sleep, but the best choice overall is to eat lightly before bed (if at all) and avoid alcohol or stimulants like caffeine. Save larger, protein-rich meals for breakfast and lunch when your body needs the daytime energy.
Studies now show that people who are sleep deprived tend to eat more fat-rich foods, simple carbohydrates, and fewer vegetables, possibly because sleep loss alters chemical signals connected to metabolism and hunger.