He takes over from Novak Djokovic and is guaranteed to set a new mark of 287 weeks in seven days' time.
is up to 21, from 76, in the men's doubles rankings after his title win with Dane Freddie Nielsen.
Djokovic slips to two in the rankings while Rafael Nadal is at three with Murray still at four.
Beaten Wimbledon semi-finalist Victoria Azarenka takes over as women's world number one from Maria Sharapova while champion Serena Williams moves up to fourth from sixth.
A year ago, after illness and injury, Williams had slumped to 175th place in
the WTA rankings.
Federer's winning moment and reaction
Britain's Heather Watson rises 24 places to a career-high 79th after the 20-year-old reached the third round at Wimbledon.
Her compatriots Anne Keothavong (75) and Elena Baltacha (99), who went out in the second round, both go up two places, but first round casualty Laura Robson falls to 113 from 97.
Fellow Brit James Ward, who also made the second round, moves up 19 to 154.
With Djokovic not playing this week, Federer is guaranteed to retain the top spot, and may well remain number one until at least the US Open, which starts on 27 August.
Federer's four-set victory over Murray secured his his 17th Grand Slam title, and his first for two-and-a-half years since he beat the Scot in the Australian Open final.
"I see it more as a stepping stone, a period I had to go through as well. To win 90% of my matches throughout the year is impossible every single year. So you're always going to go through ups and downs," said Federer.
"But I knew how close I was for the last few years, and some people didn't quite see that maybe for different reasons. But I knew and I think the belief got me to victory."
Highlights: Marray in doubles glory
Marray, 31, and his partner Neilsen win £130,000 each after the doubles final triumph over Robert Lindstedt and Horia Tecau on Saturday.
The winning pair were wildcard entries and now look likely to qualify for the ATP World Tour Finals at the O2 in London in November.
But Marray said it might not be enough to earn his first Davis Cup call for Great Britain in eight years when the team play their next match, against opponents yet to be decided, in February.
He said it would be difficult to replace the current doubles partnership of Colin Fleming and Ross Hutchins
"They've been doing great and have a great record. It would be hard to shift them out of the team," he said.
ATP men's rankings
Roger Federer (Swi)
Novak Djokovic (Ser)
Rafael Nadal (Spa)
Andy Murray (GB)
David Ferrer (Spa)
Jo-Wilfried Tsonga (Fra)
Tomas Berdych (Cze)
Janko Tipsarevic (Serbia)
Juan Martin del Potro (Arg)
Nicolas Almagro (Spa)
WTA women's rankings
Victoria Azarenka (Blr)
Agnieszka Radwanska (Pol)
Maria Sharapova (Rus)
Serena Williams (USA)
Samantha Stosur (Aus)
Petra Kvitova (Cze)
Angelique Kerber (Ger)
Caroline Wozniacki (Den)
Sara Errani (Ita)
Marion Bartoli (Fra)
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.