Federer, who did not concede a service break all week, easily handled his service games throughout the match, losing only 13 points on his serve.
He also employed an attacking style that gave Djokovic fits, winning 15 of 21 net points in the first set.
After cruising through the first set tiebreak, Federer earned the only break of the match in the second game of the second set en route to sealing the win in 90 minutes.
“I tried to really mix it up on his second serve and I was hoping to serve good enough myself to keep me out of trouble,” Federer said in his courtside interview.
“He had that one bad game at the beginning of the second set, which made the difference in the match.”
The win will give Federer a jolt of confidence going into the Aug. 31-Sept 13 U.S. Open where he will be seeking a sixth title at Flushing Meadows and first since 2008.
With the win, Federer also denied longtime rival Djokovic from completing the set of all nine ATP Masters titles and took a 21-20 edge in career head-to-head meetings.
“It’s now the fifth time I’ve been in this final. I guess I’ll have to wait until Roger retires,” Djokovic joked.
“I knew coming into the match he was going to be aggressive. No question about it. So I tried to handle it. I did well until the tiebreak in the first set. After that, he was just the better player.”
Federer will now move into second spot in the world rankings on Monday, which means the two rivals could meet again in the final at Flushing Meadows.
After the match, Federer assessed his game going into the year’s final grand slam.
“Good, regardless of whether I would have won or not,” said Federer. “I was well prepared. I had a good Wimbledon, a good offseason, recovered well and trained really hard. I knew I was going to be ready for the Open.”
(Reporting by Tim Wharnsby in Toronto; Editing by Frank Pingue)