What causes a baby to cough in the night, but not during the day?

It varies. Nighttime cough can be related to allergen or irritant exposure, uri, sinusitis, gerd or wheezing. I would contact your doctor if it is ongoing, associated with shortness of breath or is associated with fever.