Objectives: To determine age-specific seroprevalence, risk factors, and risk markers for heterosexually-acquired HIV infection among pregnant women. Design: Cross-sectional study of 12 436 consecutive pregnant women in Lima, Peru in 1996-1997. Methods: Standardized interviews, serologic tests for HIV and syphilis, bivariate and multivariate analysis. Results: HIV seropositivity was confirmed in 58 women (0.5%). Only 22.6% were married, and only 12% of HIV infected women reported ≥2 sex partners ever. In multivariate analyses HIV infection was associated with: short duration of current relationship; two risk behaviors of women themselves (early onset of sexual activity and number of past sexual relationships); women's perceptions of two risk behaviors of partners (partner is a 'womanizer', and partner uses illegal drugs); inadequate prenatal care; and four additional risk factors or markers (history of sexually transmitted disease, tuberculosis, or abortion in the women; and diagnosis of HIV/AIDS in a partner). Conclusions: HIV infection was related both to women's own risk behaviors and to the perceived risk behaviors of their sexual partners. Underlying societal factors related to heterosexual HIV infection, including deferral of marriage, warrant further study.