Berdych, seeded sixth, hadn't beaten Djokovic since a semifinal match at Wimbledon in 2010 and was just 1-14 versus Djokovic lifetime.
With a solid first set and through seven games of the second it appeared that trend would continue, but Berdych rallied for a 2-6, 7-5, 6-4 win. Djokovic said he started to play defensively after taking a 5-2 lead in the second set.
Berdych allowed Djokovic just 12 points on serve in the third set and saved the only break point he faced to seal the win.
He will seek to end another long losing streak in the semifinals against fifth-seeded Rafael Nadal, who Berdych hasn't beaten since 2006, a string that covers 12 matches.
Nadal kept his hopes of defending his 2012 Italian Masters title with a 6-4, 4-6, 6-2 win over No. 4-seeded David Ferrer. It was the second time in as many weeks the two Spanish players met in the quarterfinals, with Nadal winning in three sets both times.
Second-seeded Roger Federer held off Jerzy Janowicz 6-4, 7-6 (7-2). Janowicz opened the second set with a break but Federer got that back in the 10th game and never trailed in the tiebreaker.
Benoit Paire earned his first Masters-level semifinal appearance with a 6-1, 6-0 rout of Marcel Granollers in 57 minutes without facing a break point.
Federer takes a 2-0 career mark against Paire into the semifinals.
LGBT community has 'bullied the American people': Bachmann
Attkisson leaves CBS News, reportedly over network's 'liberal bias'