This browser does not support the Video element.
TOKYO (AP) - When Megan Rapinoe stepped up to take her penalty, she was just trying to stay as calm as possible in the moment.
"You can either take one and lose it, or take one and win it," she said. "It’s going to go one of two ways."
This one was a winner.
Rapinoe converted the deciding penalty in a shootout and the United States advanced to the semifinals of the women's Olympic soccer tournament 4-2 following a 2-2 draw with the Netherlands on Friday.
U.S. goalkeeper Alyssa Naeher stopped Vivianne Miedema's opening attempt in the shootout and then saved a shot from Aniek Nouwen before Rapinoe put her penalty away.
RELATED: Tokyo Olympics: Who to watch on Team USA
After Rapinoe converted, she turned to her teammates, folded her arms and grinned in triumph.
Afterward, she joked about the pressure.
"I just try to stay calm. I always say to myself, `The worst that's going to happen is you're going to lose the whole thing,'" she smiled.
Miedema scored a pair of goals in regulation time for the Netherlands, giving her 10 goals for the tournament — an Olympic record. But the Dutch are headed home.
Miedema put the Netherlands ahead in the 18th minute but the Americans equalized when Sam Mewis headed in a goal off a feed from Lynn Williams in the 28th. Williams then gave the Americans the lead in the 31st.
Miedema, who was playing in her 100th game for the Netherlands, made it 2-2 in the 54th. Naeher stopped Lieke Martens' penalty in the 81st minute and the game went to overtime.
"I felt amazing. I should have taken the penalty in the game," Miedema said. "I should have just stuck with my plan and go from there. But it’s life. It’s football and I just need to move on."
Naeher was as cool following the game as she was during it, playing down her own performance while lauding her teammates.
Megan Rapinoe No. 15 of Team United States celebrates with Christen Press No. 11 and Rose Lavelle #16 following their team's victory in the penalty shoot out during the Women's Quarter Final match between Netherlands and United States on day seven of …
"This team just kept pushing for 90 minutes, 120 minutes, and we just kept believing that we were going to find a way to get it done," Naeher said. "Very proud of the four players to step up and score their four penalties to go 4 for 4. That is huge."
The United States will next face familiar foe Canada in Kashima on Monday. The Canadians advanced to the semifinals 4-3 on penalties after a scoreless draw with Brazil in Rifu.
The Americans went to a shootout for the fifth time in a major tournament. The previous time was at the 2016 Rio de Janeiro Olympics, when the U.S. was bounced by Sweden in the quarterfinals.
"It's such a cruel way to end a game," Rapinoe said. "It sucks to miss one, it sucks to be on the losing end of that. But that was not us today."
Friday's game at the International Stadium brought together the two teams that played in the World Cup final two years ago in France. The U.S. women won that 2-0 and afterward the crowd chanted "Equal Pay!" in support of the team’s legal fight for equity with the men’s national team.
United States coach Vlatko Andonovski tinkered with his lineup for Friday's match, with Rapinoe, Alex Morgan, Christen Press and Rose Lavelle on the bench at the start.
The grueling game was the latest hurdle in what has been a particularly uncharacteristic tournament for the United States. The normally stalwart Americans lost to Sweden 3-0 in its opener before beating New Zealand 6-1. They then advanced to the knockout round following a 0-0 draw with Australia.
The United States hadn’t been shutout since 2017.
The Netherlands, meanwhile, poured on the offense in the group stage with an Olympic record 21 goals — smashing the previous record of 16 set by the United States in 2012.
Miedema, who plays for English club Arsenal, is only 25 and is already the all-time scoring leader for the Netherlands with 84 goals in 100 appearances. She is also the leading scorer in the Women’s Super League in England.
The United States also played the Netherlands in Breda in November, winning 2-0. The Americans were unbeaten in 44 straight matches before the loss to Sweden at the Tokyo Games.
In Rifu, Canada goalkeeper Stephanie Labbe stopped Rafaelle’s attempt and was rushed by her teammates. Canada has won bronze medals at the past two Olympics.
Australia earned its first trip to the semifinals by beating Britain 4-3 in extra time in Kashima. The Matildas will face Sweden, who beat host Japan 3-1 in Saitama.