WIMBLEDON, England — American Coco Gauff, the youngest player to qualify for the Wimbledon main draw in the modern era, continued her stunning run Friday with a third-round victory over Polona Hercog of Slovenia. The 15-year-old was on the wrong end of two match points in the second set before rallying to a 3-6, 7-6 (9-7), 7-5 win.

Gauff, from Delray Beach, Fla., is the youngest player to reach Wimbledon’s round of 16 since Jennifer Capriati advanced all the way to the semifinals in 1991, also at 15. She is the only player in the women’s field who is so young that tournament officials have to limit her playing time under rules designed to protect players under 18 from burnout.

On Monday, Gauff will meet No. 7 seed Simona Halep, the 2018 French Open champion and a four-time Grand Slam finalist.

Gauff, who earned her spot in the main draw as a qualifier and is ranked 313th in the world, was asked afterward how she maintained her composure when she was trailing. “I always knew I could come back no matter what the score was,” she said, “and I just kind of went for my shots.”

From the start of the match, she was a crowd favorite, greeted on Centre Court by a round of applause and during her rough patches by shouts of “Go, Coco!”

The match, which lasted 2 hours 47 minutes, was the biggest win of her fledgling career. Having already dispatched five-time Wimbledon champion Venus Williams in the first round and 2017 semifinalist Magdalena Rybarikova in the second, Gauff was not overwhelmed by the moment.

She said the crowd was “amazing.”

“Even when I was down match point, they were still cheering me on,” Gauff said. “I’m just super thankful that they believe in me.”

It wasn’t the prettiest tennis. It often wasn’t very aggressive or free-swinging. There weren’t a lot of aces, and there were a combined 88 unforced errors (45 for Hercog, 43 for Gauff). On Hercog’s second match point in the second set, the 28-year-old double-faulted.

But Gauff’s win showed remarkable mental toughness by a player who isn’t old enough to vote. She never cracked. And her backstory is Hollywood-ready: an American teenager playing on Centre Court at Wimbledon, a few days after a debut when she bested Williams, her idol, in straight sets.

Asked what she was going to do with her almost $200,000 in Wimbledon winnings, Gauff said, “I mean, I can’t buy a car because I don’t drive.” She said she didn’t like spending money but ventured that maybe she would buy some hoodies.

Hercog broke Gauff’s serve midway through the first set and then again early in the second. Hercog, ranked 60th in the world, won seven straight games by relying on a big first serve. As the match wore on, however, that weapon deserted her.

In the second game of the second set, after her service was broken, Gauff slumped and dropped her racket in frustration. But when it looked as if Hercog would run away with the match, Gauff rallied, fighting off the match points and taking Hercog to a tiebreaker, the first of Gauff’s professional career.

That tiebreaker was tense, dominated by long, nervous defensive rallies, slicing and slicing, each player hoping the other would falter. Gauff finally won the set after a 32-stroke rally, then despite a few missteps, took the third, too.

Gauff’s debut at Wimbledon began Monday, when she committed just eight unforced errors in a stunning victory over Williams, a 39-year-old icon who won four Grand Slam titles before Gauff was born.

After beating Williams, Gauff took just a second to shed a tear. Asked what it felt like to beat her role model, she said, “Honestly, I don’t know how to feel” and confessed, “I never played on a court so big.”

That was before she played Court 1, and then Wimbledon’s big stage, Centre Court.

“I look at the way she plays,” said John McEnroe, the three-time Wimbledon champion and commentator, after her debut. “If she’s not number one in the world by 20, I will be absolutely shocked.”

She has handled herself with grace, charming the crowds at Wimbledon and British fans in general. Gauff was featured on the front pages of several British newspapers after the upset.

“Wimbledon sensation” was the headline on the front page of the Daily Telegraph. “WIMBLEDON GOES COCO NUTS” blared the Daily Mail. And Twitter went a little nuts, too: Gauff’s name was trending on UK social media sites.

“I have seen the future of Women’s tennis and her name is Coco Gauff,” one post read.

“I literally went mental. We are witnessing something special. Coco Gauff is special . . . 15 years old, amazing,” another read.

Gauff started playing tennis at age 7. Her parents were college athletes; her father, Corey, played basketball at Georgia State, and her mother, Candi, ran track at Florida State.

Martin Blackman, general manager for player development at the U.S. Tennis Association, has been watching Gauff play since she was 10.

“We’re a little surprised, too. Not so much at how good she is but how she got so good as quickly as she has,” Blackman said. “We knew she’d be great, maybe not until she was 16 or 17. But at 15, to play and beat Venus? That happened fast. . . . When you watched her play Venus, she was amazing. You can’t believe she’s only 15 years old. The symbolism in the match against Venus was extraordinary.”

This is no fluke, he promised. “Sky’s the limit with her.”

Matthew Gutierrez in Washington and Karla Adam in London contributed to this report.