Yes, you can eat pineapple before bed, especially because it contains melatonin, which can help you fall asleep easily. However, as with any fruit, there is still sugar in pineapple, so eating too much can cause your blood sugar to spike at night and may result in weight gain. Mix the fruit with some Greek yogurt for extra protein, and always measure the amount you eat.