Roger Federer, Andy Murray

[SPOILER ALERT: The following story reveals the outcome of Sunday's men's tennis singles final.]

Revenge sure is sweet — especially when it ends in gold.

One month after the most devastating loss of his career at Wimbledon, Andy Murray routed Roger Federer in the Olympics singles final to win gold before a rapturous home crowd Sunday.

Murray thrashed the Swiss 6-2, 6-1, 6-4, sweeping nine games in a row at one point with booming serves, nifty passing shots and his stellar movement.

Olympics: Who completed the career grand slam: Serena Williams or Maria Sharapova?

2009 U.S. Open champ Juan Martin del Potro of Argentina defeated five-time slam champ Novak Djokovic of Serbia 7-5, 6-4 for the bronze.

The win is a breakthrough for Murray, 25, who's 0-4 in Grand Slam finals. The Scot lost to Federer in four sets on the same court — Wimbledon's Centre Court — four weeks ago, extending Great Britain's male Grand Slam champ drought to 77 years. The gold is also the first for Britain in tennis since 1908.

Olympics week 1: The best tweets

For Federer, who turns 31 on Wednesday, the silver means there's still a gaping hole in his resume. He was aiming to cement his status as the greatest tennis player ever by completing the career Golden Slam (win all four Grand Slams and Olympic gold). Only four players have done it: Steffi Graf, Andre Agassi, Rafael Nadal and Serena Williams, who achieved it Saturday. The 17-time slam champ, who won doubles gold in Beijing, may have still been reeling from his record-breaking semifinal epic against del Potro on Friday, which lasted 4 hours and 26 minutes. He shanked error after error and failed to convert on nine break points, including six in the third game of the second set.

Murray, on the other hand, was five-for-10 on break points. He closed out the match with an ace — his fifth — as the rocking British fans erupted in cheers.

Murray later won silver in mixed doubles with Laura Robson, losing to Belarus' Victoria Azarenka and Max Mirnyi 2-6, 6-3, [10-8].