In a rain-affected match, a repeat of the 2010 Shanghai Masters final which Murray won, the British number one produced a masterful display as he secured crucial breaks in both sets to defeat the top seed.
Murray now leads the pair's head-to-head record on the ATP Tour 10-8, and he left the Swiss exasperated throughout, winning a staggering 87 per cent of his first-serve points to set up a showpiece encounter with second seed Novak Djokovic, who beat Tomas Berdych in the first semi-final.
For Federer, who was attempting to win a record 22nd ATP World Tour Masters 1000 trophy, it was a frustrating day as his serve let him down on numerous occasions under pressure from the US Open champion.
Murray reeled off two stunning forehand winners as he broke immediately to begin the match very strongly, with Federer only able to find one first serve in a slightly sluggish opening game for which he was ruthlessly punished.
The British number one’s advantage proved to be fleeting, however, as Federer hit straight back with a flurry of testing returns, and Murray was left berating himself after a sloppy forehand went wide to concede the break.
Astonishingly, Federer committed three successive double faults in the fifth game as he effectively gifted his opponent a simple break of serve, a startling blip from the world number one.
Though Federer’s service was back to normal for the remainder of the set, the Swiss star could not hit back. Murray was unwavering on his delivery, the Scot simply not allowing his opponent any opportunity to force his way back on terms.
Murray drilled two stunning forehand winners beyond Federer’s defences as he moved to within a game of the set, and he proceeded to close it out first with a huge ace out wide and then another forehand winner.
It was tennis of the very highest calibre from the US Open champion, and Federer looked uncharacteristically rattled as he proceeded to struggle on serve at the start of the second set.
A seemingly interminable opening game of the second set was locked at deuce as Federer gallantly saved seven break points and, after a brief delay as the Swiss debated the court conditions with the umpire, he eventually came through to hold and close out a quite epic game.
The set never settled down as both players unleashed a barrage of stunning shots to disrupt each other’s serves, but the turning point came when Murray astonishingly managed to haul himself back from 40-0 on Federer’s serve to break and go 3-2 ahead.
Murray consolidated his break of serve despite coming under immense pressure from the world number one, and he held firm to preserve his advantage with Federer unable to muster a break back.
The defending champion was ready to serve out for the match at 5-4, only for a very ill-timed second rain interruption that forced the players off the court as the roof was belatedly shut on the Stadium Court.
Eventually, after a frustrating delay for both players, Murray had to gather himself to attempt to serve out for the match. He did so with aplomb.
Murray secured his progression through to the final in nerveless fashion, and he remains firmly on course to win his third successive title in Shanghai, with just his good friend Djokovic now standing in his way.