From Dr. Sears:
Breastfeeding can suppress ovulation and thus serve as a form of birth control. When you breastfeed, the same hormones that make milk, called prolactin, also suppress the release of hormones that cause eggs to mature and become fertile and the lining of the womb to nourish fertile eggs. This is why breastfeeding mothers usually notice a delay in the return of their menstrual periods. This delay, called lactational amenorrhea, or LAM, may be nature's way of telling you that one baby is all your body can handle right now, and it's too soon for a sibling. As a natural method of birth control, LAM's effectiveness rate can be as high as 98 percent (similar to artificial methods), but only if you observe the following practices:
Breastfeed frequently. In order for the level of milk-making hormones to stay high enough to suppress fertility hormones, frequent, unrestricted breastfeeding is necessary. This usually means breastfeeding at least every two to three hours during the day, or as often as baby needs.
Night nurse. Since fertility hormones tend to be highest during the sleeping hours, it's also important to keep the milk-making hormones that suppress ovulation high at night. Since co-sleeping babies usually breastfeed more frequently during the night, having your nursing baby nestle right next to you during the night is one of the most effective ways to delay fertility. Once your baby starts sleeping through the night, the fertility hormones take over and breastfeeding is no longer likely to lead to natural child spacing. If you plan to train your baby to sleep through the night, your fertility is likely to return soon.
Avoid supplemental bottles and pacifiers. To keep the milk-making hormones high enough to suppress ovulation, it's important that all of baby's sucking be at the breast.
Delay the introduction of solid foods. Wait until baby is at least 6 months to introduce solid foods, and then make them an addition to, not a substitute for, breastfeeding. If you notice your baby is decreasing the number of nursings once you start introducing solid foods, back off a bit on the solids.