The British fourth seed thrilled the Centre Court crowd by fighting back from a set down to book a last-four meeting with Frenchman Jo-Wilfried Tsonga.
Murray gradually wore down tenacious seventh seed Ferrer after a nail-biting second-set tiebreak in which he fell 5-2 behind and saved a set point at 6-5 down before taking it 8-6.
He clinched the third set with an ace before a short rain interruption with the score 5-5 in the fourth and he won the decisive tiebreak 7-4, sealing victory in three hours 52 minutes with another ace.
The Scot, who sent down 18 aces altogether, said it was tense in the dressing-rooms during the rain interruption.
"At the break I went for a shower and threw some cold water on my face. It was a very intense atmosphere," he said.
"It was a huge match for both of us. Coming off at a critical stage, if I lost that fourth set it was going to be a very tough match."
In a clash packed with intriguing long rallies, Murray fought back from 5-2 down in the first set after a dominant start by Ferrer, a tenacious performer with four titles to his name this year.
Ferrer, who had previously dropped just one set in the tournament, had a set point in the first set at 5-4 but the Scot fended it off before the Spaniard came through to win the tiebreak 7-5 in a little over an hour.
Each player had a break in the second set with Ferrer setting himself up to serve for a 2-0 lead after Murray chipped wide, one of his few errors at the net.
However, Murray broke straight back as Ferrer uncharacteristically put two successive balls wide playing to his opponent's backhand.
Murray, seeking to become the first British man to reach the Wimbledon final since 1938, was full of praise for his opponent.
"He's a great player, he's number five and doesn't always get the respect.... he's an unbelievably hard worker," Murray said.