Pregnancy lasts for about 280 days or 40 weeks. A preterm or premature baby is delivered before 37 weeks of your pregnancy. Extremely preterm infants are born 23 through 28 weeks.