World No.1 Andy Murray has been knocked out of the Monte Carlo Masters on Thursday after Spaniard Albert Ramos battled back from 4-0 down in the final set to win 2-6 6-2 7-5 and reach the quarter-finals on a day of upsets.
Swiss third seed Stan Wawrinka, the 2015 French Open champion, was also sent packing when he lost to Uruguay's Pablo Cuevas 6-4 6-4.
Murray was playing only his second match since returning from a five-week lay- off after an elbow injury. He was handed a first-round bye in the first European claycourt tournament of the season.
'I'm disappointed to lose from the position that I was in. Being 4-0 up in the third, I haven't lost many matches like that in my career,' Murray said.
'He obviously started playing better towards the end of the set. I still had a bunch of chances. I guess both of us did, really. I should have been able to do enough to weather that storm a little bit and finish the match off.'
The Scot won the opening set at the Monte Carlo Country Club in 48 minutes but his service was suspect and Ramos, ranked 24th in the world and the 15th seed, ripped through the second to go into the third with all to play for.
He kept his head in the Monaco sunshine even after Murray, who ended up being broken seven times in a match with 13 service breaks, had romped to a 4-0 advantage with the loss of just three points.
The Spanish clay court specialist won four games in a row, before Murray applied some late pressure, and was implacable as he won the next two with back-to-back breaks and served for the match.
Murray saved one match point, when a Ramos backhand went wide, but misjudged a drop shot that landed in the net to hand Ramos a famous first victory over his top-ranked opponent.
The Scot reached the semi-finals in Monaco last year and clearly needs more matches ahead of the French Open starting on May 28.
Ramos will now play fifth-seeded Croatian Marin Cilic, who beat Tomas Berdych 6-2 7-6, on Friday.