The 24-year-old Aussie, who struggled through the opening set, claimed the $365,390 top prize and his sixth career ATP crown at the US Open tuneup event.
"This is probably my best memory of a final," Kyrgios said. "I left it all on the court."
Kyrgios, 5-1 this year against top-10 rivals, won his second title of the season after Acapulco in March and will jump 25 positions to 27th in Monday's new rankings, his first top-30 appearance in 43 weeks.
"This has been one of the greatest weeks of my life. I've made massive strides," Kyrgios said. "This whole week has been amazing. It's a week I won't forget."
Known for his fiery temperament and inconsistency, Kyrgios was resilient all week, breaking racquets but holding his emotions together -- "super proud" of his composure.
"In the past six months, it's crazy to think how much I've been able to turn it around," Kyrgios said. "I'm working hard to be better as a player and a person.
"I lost faith that I could still have weeks like this and be happy. I've got to thank (my family) for not losing faith.
"I just wanted to clean myself up and have a healthy attitude. I showed what I can do this week."
While saying his best memory of the week was "how professional I was off the court," Kyrgios also noted, "I've got a long way to go."
American Jessica Pegula captured her first WTA singles title by ripping Italy's Camila Giorgi 6-2, 6-2 in the Washington women's final.
The 25-year-old daughter of NFL Buffalo Bills owner and natural gas magnate Terry Pegula took a $43,000 top prize.
Kyrgios won a match that featured no break points or deuces after 94 minutes with back-to-back aces, the last his tournament-best 110th of the week.
Medvedev, 23, was broken only twice this week but lost his lone sets to Kyrgios. He'll equal his career-best ranking of ninth on Monday.
"I know how well Nick can play when he wants to play. This week, I think he wanted to play and it was tough," Medvedev said.
"He was determined and it seemed like he wants to win. And that's what we don't see all the time."
Kyrgios, who beat Medvedev on Rome clay in May in their only prior meeting, would face him again in the second round next week at Montreal if Kyrgios beats Britain's Kyle Edmund.
"It's never easy to play Nick," said Medvedev, adding with a laugh. "I hope Kyle wins."
Kyrgios first grabbed his back at 2-all, stretching and twisting during a changeover but having no troubles after treatment between sets from a physiotherapist.
"I just happened to get through that first set, which was massive," he said.
His running and service speed were hampered at times during his seventh match in as many days counting doubles, but while Medvedev took 24 of 25 points on his serve, Kyrgios matching up into the tie-breaker.
Kyrgios denied Medvedev on set point with a 124-mph ace, then hit a passing winner and won it when Medvedev sent a forehand wide. In the last breaker, two Kyrgios aces made his Washington's first unseeded ATP champion since 2011.
- Pegula powers to crown -
==========================
Pegula's only other WTA singles final was last September at Quebec City, where she lost to France's Pauline Parmentier.
Pegula, who will jump 25 spots to a career-best 54th on Monday, broke early in each set and closed matters just inside an hour with an ace.
"It's extremely gratifying," she said. "The journey makes it all that much sweeter because it's hard. I really pushed myself this week. It's amazing. I'm excited.
"Hopefully I can take the momentum and keep riding it."