NEW YORK — When Ben Shelton and Frances Tiafoe took to the Arthur Ashe Stadium Court in front of more than 20,000 fans Friday afternoon, the latest chapter of American tennis history was on the line.

Tank tops, monster serves and exuberant personalities were all around.

Defending U.S. Open women’s champion Coco Gauff, who is friendly with both players, said after her earlier win the men’s match was “going to be fun to watch.”

Seven-time Grand Slam champion John McEnroe lamented that the Shelton-Tiafoe third-round blockbuster began during the day instead of under the lights because defending champion Novak Djokovic requested the night match.

“This would’ve been electric at night,” McEnroe said on ESPN.

In the matchup of two former U.S. Open semifinalists that featured rocket serves and concussive baseline slugging, No. 20 Tiafoe, the 26-year-old from Maryland, prevailed over No. 13 Shelton, the 21-year-old left-hander from Atlanta and former NCAA singles champion, 4-6, 7-5, 6-7 (5), 6-4, 6-3 in 4 hours, 3 minutes. Tiafoe converted 5-of-21 break points on Shelton, who had not been broken coming into the match.

Banging serves as fast as 143 mph, the biggest of anyone at this U.S. Open, Shelton crushed 22 aces but is now 2-1 against Tiafoe.

“First off I gotta say Ben is an incredible player, he’s an incredible player,” Tiafoe said on court. “He really is; he goes for all kinds of shots. He’s got no care in the world. It’s really annoying. He’s got a great serve, he’s really talented out here.

“It’s just highlight after highlight, I really hope you guys enjoyed the show. Four hours, it was just a battle.”

It was a rematch of last year’s quarterfinal epic won by Shelton in four sets. He then lost to Djokovic in the semis but it is Tiafoe who could now face the 24-time Grand Slam champion in the round of 16 on Sunday.

No American man has won a major title since Andy Roddick at the 2003 U.S. Open, and European men have won 77 of the last 78 major titles. Of course, the ‘Big 3′ of Djokovic, Roger Federer and Rafael Nadal have combined for 66 Slams since Wimbledon 2003. But five American men are currently ranked inside the top 20.

“Everybody wants that big next Grand Slam, next big moment,” Shelton said ahead of the match. “But the gradual improvement and progression is what’s really going to put Americans more towards the top of the game.”

Tiafoe is Black and Shelton biracial, and both have encouraged younger players from diverse backgrounds to pick up a racket. Still, the two players come from vastly different backgrounds. Bryan Shelton, Ben’s father, is a former tour pro who later coached his son at the University of Florida. Tiafoe’s dad, Frances Sr., was a janitor at a Maryland tennis center where his son first was introduced to the game.

Now both are part of the new wave of American talent, which also features No. 12 Taylor Fritz, who also advanced into the fourth round.

In the decisive fifth set, Tiafoe earned a break for 3-1 when he approached the net and put away a forehand volley.

Serving at 5-3, Tiafoe closed it out on his serve with a forehand volley winner into the open court. Shelton let out a big smile and the two men embraced at the net.

In the first set, Shelton earned a break for 3-1 when he returned a 128-mph Tiafoe serve with a wicked backhand winner and let out a “Yeah.”

Tiafoe broke back with a backhand volley winner to draw within 4-5. It was the first time Shelton had been broken in the tournament.

But Shelton broke right back to seize the first set 6-4 when Tiafoe netted a backhand on the second break point.

In the second set, Shelton fought off five break points to hold for 4-3.

He then fended off three more break points serving at 4-all, 0-40.

But Tiafoe broke him for 6-5 when Shelton slapped a forehand wide. Tiafoe leveled it at one set apiece when he held serve when Shelton netted a backhand.

In the third set, Shelton seized control with a break for 5-3 when Tiafoe missed an easy volley and then double-faulted on break point.

Shelton gave the break back when he double-faulted to make it 5-4.

In the tiebreak, Shelton raced to a 6-0 lead but nearly gave it all back before banging out a 143-mph ace to take a two-sets-to-one-lead.

Shelton dropped the fourth set when he sailed a backhand off the court while serving at 4-5. The crowd roared in anticipation of a fifth set.

Off the court, the two outsized personalities enjoy one another’s company.

“I think that we’re both kind of goofy, especially in the locker room,” Shelton said. “He definitely knows how to bring out the clown side of me. I do the same with him.”

He added: “One of the things that I love about him is he can turn the switch off when he’s off the court and in the locker room and hanging out, but he can really turn it on when he wants to, and he’s on the court.”

Though Shelton is out of the tournament, his future remains bright.

“He’s only 21,” McEnroe said. “He’s gonna get better.”