If a friend has a baby, watch out: You could be next.

Women are more likely to have children in the two years after their high school friends have their first child, a new study finds.

"Friendships that were formed a long time ago have a big influence on the decision to have a child," said study co-author Nicoletta Balbo, a sociologist at Bocconi University in Italy.

But exactly why pregnancies are contagious isn't clear. While peer pressure may play a small role, the link persists even when accounting for that influence, as well as the fact that friends may be more likely to have similar life circumstances, Balbo said.

Long-term relationships

The researchers looked at 1,726 American women who participated in the National Longitudinal Study of Adolescent Health (Add Health), a nationally representative survey of teenagers begun in 1996. The teens answered a slew of questions about their closest friendships, and the researchers also gathered information on the respondents' health, life course and family.

At the start of the study, the girls were at least 15 years old; they were 30 years old in the follow-up survey, taken between 2008 and 2009. About half the women who had children had given birth by age 27. (Statistical problems with the fertility data prevented the researchers from analyzing men.) [Blossoming Body: 8 Odd Changes That Happen During Pregnancy]

Baby contagion

Women were more likely to have their first babies two years after a high school friend had her first child, provided the friends still kept in touch.

This effect was much stronger than the impact of schoolmates who weren't friends having children. The influence held even when the researchers took into account other factors associated with the timing of family planning, such as socioeconomic status, family background, age and race.

Once a high school buddy had her first baby, the probability of her friends becoming parents rose slowly, peaked at two years, and then receded, the researchers found. This timing suggests that the friendship had an influence on people's decision to have a kid, rather than friends simply deciding to have kids at the same time.

Unknown cause

Exactly why this happens isn't clear. One possible explanation is that seeing a close friend have a child may simply get women used to the idea, according to the researchers.

"You see your best friend having a child. You start meeting her with the baby, and you see what being a parent looks like," Balbo told Live Science. That could make people more willing to have children of their own, assuming those who have children seem happy, she said.

It may also be less costly, materially and socially, for friends to have children around the same time, Balbo said.

Friends who both have children can borrow baby clothes, toys and other kids' gear. They also avoid having to make new friends to match their new life stage. For instance, taking a holiday together with friends is easier if everyone (or no one) has kids, Balbo said.

As a follow-up, the researchers want to see if having children is contagious amongst friends in its own right, or because of other life decisions that often precede childbearing.

"Maybe these people end up having a child more or less at the same time just because they got married or started to cohabit more or less at the same time," Balbo said.

The findings were published in the June issue of the journal American Sociological Review.

Copyright 2014 LiveScience, a TechMediaNetwork company. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.