When Neil Armstrong clambered down on to the surface of the moon, he famously declared that he had taken “one small step for [a] man, one giant leap for mankind”.

But what if that one small step had been taken by a woman? What kind of leap would that have represented, at a time when the American public was waking up to women’s rights?

That’s the focus of Mercury 13, a Netflix documentary that explores the fates of 13 female pilots who were prevented from entering Nasa’s space training program.

The women featured in the film passed through some of the same physiological and psychological testing procedures as Nasa’s first male astronauts, as the space race with Russia ramped up in the early 1960s. In some cases, the women, each of them skilled flyers, fared better than their male counterparts, but their testing, which was designed to assess their suitability for space flight, was conducted with private funding without the approval of Nasa.

As the women prepared to undergo further testing, which would have included flying jet planes, Nasa refused to extend the project. The women’s dreams were shattered, and it would be more than two decades before an American woman made it into space.

After the release of Hidden Figures in 2016, which told the story of three black women who struggled for acceptance at Nasa during the space race, Mercury 13 offers a further glimpse into the difficulty women faced in breaking into the field.

“I think it’s important to tell people that women were involved in the space program. There’s lots of films about the space program and lots of stories about the space program but they generally focus on men,” said Heather Walsh, who co-directed Mercury 13 with David Sington.

“So I think it’s good to draw out these stories and show that women might not have been talked about but they were there, and they did help, and they did do their bit.”

The film follows the story of the 13 women and their legal battle before Congress in 1962, arguing that they were prevented from further space testing and training on sexual discrimination grounds.

Their case captured the imagination of the American public, but was rejected by President Johnson. It was a missed opportunity. Russia sent the first woman – Valentina Tereshkova – into space in 1963, winning a propaganda battle that the US could have otherwise claimed.

Walsh believes there would have been greater implications than just a propaganda victory, had the US backed the Mercury 13 women.

“I think everything would have changed. I think there would have been a female president by now,” she said. “Being an astronaut at that time was the pinnacle of what you could do. You know, the whole world was watching. And when you step out on to the moon there wasn’t a person on the planet that didn’t want to see you and didn’t know who you were.

“And I think if that person was a woman it would have would have changed things. It would have seemed normal for women to do anything.”

Jerrie Cobb beside her jet fighter in 1961. Photograph: AP

Mercury 13 interviews Wally Funk, Rhea Woltman, Sarah Ratley and Gene Nora Jessen, each of the women participated in space-readiness testing conducted by Dr William Randy Lovelace, who had helped develop the physical and psychological examinations used to select the first team of astronauts for the Nasa training program.

Named Project Mercury, it was America’s first human spaceflight program, and would see Alan Shepard become the first American in space in 1962.

Lovelace was close friends with Jacqueline Cochran, whose pilot skills had propelled her to fame in the 1930s. Cochran had set women’s national speed records and was involved in setting up establishing Women Airforce Service Pilots, who performed non-combat flying missions during the second world war.

Cochran and Lovelace felt women had a role to play in space. Outside his contract with Nasa, Lovelace began a private screening program, conducting the same tests he had devised for men on female pilots.

Jerrie Cobb, who later became a staunch advocate for female flyers, was the first to undergo space testing, but faced resistance in the media. Mercury 13 shows one clip from a television interview in the early 1960s that particularly illustrates the opposition the women faced. In the interview Cobb is quizzed as to why “there is a need” for women in space.

She answered: “Well it’s the same thing as is there a need for men in space. I mean, if we’re going to send a human being into space we should send the one most qualified. And in certain areas women have to offer, in other areas men do. I think we ought to use both.”

Sington, who previously directed In the Shadow of the Moon, a documentary about manned US missions to the moon, said he and Walsh had originally hoped to bring Hillary Clinton’s success in the 2016 election into the film.

Clinton has often told a story about writing to Nasa as a teenager, asking how she could become an astronaut. She said she received a letter back “saying they weren’t accepting women”, and Sington said contrasting that experience with her subsequent presidency would have provided an uplifting ending.

Clearly, that didn’t happen.

We’ll never know if Walsh is correct – and if we would have had a female president by now had a woman been the first to walk on the moon. Even if the Mercury 13 had passed the aptitude tests, they might still have been rejected – perhaps Armstrong and Buzz Aldrin would still have proved more able, and the first person on the moon would still have been a man.

But as Cobb told her skeptical interviewer in the 1960s: women should have been given the opportunity to try.