Novak Djokovic beat Argentine third seed Juan Martin del Potro 6-3 7-6(4) 6-3 in the US Open final for his second Grand Slam title of the season and 14th of his career.
The Serbian outlasted the Argentine in three hours and 15 minutes on Arthur Ashe Stadium.
A gloomy season that started with elbow surgery following the Australian Open is turning into a brilliant finish for the 31-year-old Serb who has now won three of his last four events including back-to-back majors at Wimbledon and Flushing Meadows.
Over the last eight weeks Djokovic has resembled the Grand Slam machine that held all four major titles at the same time in 2016.
Djokovic now joins Pete Sampras in third place on the all-time list of Grand Slam titles, trailing only Roger Federer (20) and Rafael Nadal (17).
"When I had the surgery on my elbow I could truly understand what Juan Martin was going through," Djokovic said.
"Difficult times but you learn from adversity. You learn when you're down, when you have doubtful moments.
"I tried to take the best out of myself in those moments and get myself in this position."
Playing on the same court where Sampras claimed the last of his 14 slams, Djokovic has endured more disappointment than joy in Arthur Ashe Stadium, losing five finals.
However, the despair on Sunday belonged to a teary del Potro, who was back in a grand slam final for the first time since his one and only title in New York in 2009.
"I'm so happy to be playing the final against this magnificent idol. Of course I'm sad because I lose but I'm happy for Novak, you deserved to win," del Potro said.
"I got it after nine years, which is amazing to me because the US Open is my favourite tournament and I'm proud of that."
Djokovic was far superior to del Potro in the opening set but he dropped three consecutive games in the second to trail 4-3.
The sixth seed survived three break points in the following game, an epic that lasted more than 20 minutes, in a pivotal moment.
A series of missed forehands by del Potro in the tiebreaker put Djokovic back on course and he finished with a flourish, taking the last three games - sealing the title on his first match point.