Managing heartburn during pregnancy involves several lifestyle and dietary adjustments. Pregnant women are advised to eat smaller, more frequent meals, avoid spicy and fatty foods, and not lie down immediately after eating. Elevating the head while sleeping and wearing loose clothing can also help.