LONDON — From the way Novak Djokovic repeatedly smacked his racket against his shoe after one miss, to the shouts directed at himself and his coach after others, it was clear how much he wanted to prove he’s past the roughest patch of his career.

Djokovic sent the strongest signal yet he is back at the top of tennis by reaching his fifth Wimbledon final with a 6-4, 3-6, 7-6 (9), 3-6, 10-8 victory over rival Rafael Nadal on Saturday in a match suspended overnight.

“It really could have gone either ways,” said Djokovic, who is bidding for a fourth championship at the All England Club and 13th Grand Slam title overall. “Basically until the last shot, I didn’t know if I was going to win.”

He’ll face Kevin Anderson in Sunday’s final. Anderson beat John Isner in a 6½-hour semifinal that ended at 26-24 fifth set Friday night, pushing back the start of Djokovic vs. Nadal.

The second semifinal then was halted when the third set ended just past 11 p.m., because of a neighborhood curfew. It had started with Centre Court’s retractable roof closed and so concluded that way, too, even though there was no hint of rain.

It all made for an unusual schedule, with the start of the women’s final — normally the stand-alone showcase on the fortnight’s last Saturday — delayed until Nadal and Djokovic finished.

Djokovic hasn’t won a major in more than two years, dealing with an injured right elbow that was so painful in 2017 he quit his quarterfinal at Wimbledon and sat out the rest of the season. He had surgery in February, but his results were still shaky.

Until now, that is. His defense and returning are as good as ever and made the difference in his 52nd career tour-level meeting with Nadal, more than any other two men have played.

“In my opinion, he deserved it,” Nadal said. “I deserved it, too.”

Undaunted by losing a lead and being forced to an extra set, Djokovic saved break points at 4-all and 7-all in the fifth, before breaking Nadal at love to end things.

“It’s hard to pick the words,” said Djokovic, who has won his past eight five-setters at Wimbledon. “I’m just going through things, flashbacks of the last 15 months, and everything I’ve been through to get here.”

As intense as any athletes in any sport, these two didn’t exactly slowly ramp things up when they returned to Centre Court about 14 hours after they’d departed. Having the roof shut meant every sound was amplified as it ricocheted off the dome — the thwack of ball off racket, the players’ grunts, the spectators’ applause.

This was high-decibel, high-stakes, high-quality tennis between two of the greats right from the get-go, beginning with an 18-point, six-deuce game that last 15 minutes and felt truly pivotal. It included a 23-stroke exchange and three others of at least 11. Nadal saved two break points and when he finally held, the owner 17 major championships, two at Wimbledon, punched the air and yelled as if he’d won the match, not a solitary game.

When Nadal broke in Saturday’s second game, a dismayed Djokovic grabbed a spare ball and whacked it with his racket against the wall behind the baseline. Fortunately, he was at the end of the court farthest from the Royal Box, where the pair of visiting Duchesses, Kate and the newly married Meghan, sat in the front row.

There were other such displays of emotion from Djokovic, who is prone to yelling at himself or at his coach.

He reacted by getting broken again to trail 5-3 in that set by raising his left shoe and violently pounding his racket against it — one, two, three, four times. Moments later, he got to love-40 before Nadal took five points in a row to serve out the set.

But it was Djokovic who tended to be better down the stretch in his 52nd career meeting against Nadal in a contest that seemed as if it should be worth a trophy.

Might very well have been.

Not only is Anderson far less accomplished than either of these two — he owns zero Grand Slam titles — but he also is coming off a pair of strenuous five-setters, including his 13-11 win against eight-time Wimbledon champion Roger Federer in the quarterfinals.

There’s no doubt Djokovic will be a big favorite, even if he did need to play nearly 2½ hours Saturday while Anderson was able to rest and relax and recover.

“It’s been a roller-coaster ride for him the last couple rounds, but he had a day off, which means a lot,” Djokovic said. “I wish I could have one.”