(CNN) -- Serena Williams wept with delight after becoming the oldest woman to ever hold the number one world ranking.
The 31-year-old American star clinched a 3-6, 6-3, 7-5 victory over Petra Kvitova in the quarterfinals of the Qatar Open to move back to the summit following a two-and-a-half year interval which almost saw her quit the sport.
"I am so sensitive nowadays -- I am always crying, but I never thought I would be here again you know," Williams told reporters.
"I have been through so much and I never thought I would be here," she repeated.
Williams first became World No.1 on July 8, 2002 at the age of 20 and will take top spot for the sixth time her career.
It is a remarkable comeback for Williams, who slipped as low as 175 in the rankings after missing almost a year with injury and a life threatening pulmonary embolism in 2011.
But she returned with a bang in 2012, winning Wimbledon, Olympic Gold, the U.S. Open and the WTA Championships, while she has also triumphed in 59 of her past 62 matches.
Williams, who will start her 124th career week at No.1 on Monday, beat Chris Evert's record of 27 years ago when she reached the top at the age of 30 and 11 months -- six months younger than her successor.
That's a total only bettered by Steffi Graf (377), Martina Navratilova (332), Evert (260), Martina Hingis (209) and Monica Seles (178).
The achievement had looked in doubt with Williams 4-1 down in the final set, but the American fought back to clinch a dramatic 7-5 victory.
Williams will now face Maria Sharapova in the semifinal after the Russian defeated Australia's Sam Stosur 6-2 6-4, while Victoria Azaraenka also progressed to the last four after defeating Sara Errani.
Meanwhile, defending champion Roger Federer crashed out of the Rotterdam World Tennis tournament after suffering a shock 6-3 7-5 defeat by France's Julien Benneteau.
The World No.2, who won the tournament in 2005 and 2012, was hoping to bounce back after losing out at the semifinals of the Australian Open.
"I'm very disappointed, I have some regrets about this match," he told reporters.
"He played great and created more chances than I did. He deserved to win. It was a tough loss, but they do happen. Being broken so many times (five) indoors won't get the job done. My game was up and down overall.
"He made it difficult and generated pressure. That made you try to serve harder. When I had some chances I didn't take them. I was maybe a point or two away from taking it into a third set and then the clock resets."
Benneteau, the world 39, will play a Saturday a semifinal against either fifth seed compatriot Gilles Simon or Slovak Martin Klizan.
"This was a dream match, and I played like a dream," he told reporters.
"This is for sure my biggest win. He was the favorite, but maybe he played a bit tight. I've been playing well all week, improving with each match.
"I've had a great week here so far and I hope it's not finished."
Second seed Juan Martin del Potro cruised into the semifinals with a victory in straight sets against Finland's Jarkko Nieminen.
The Argentine won 6-3, 6-4, and will now face unseeded Bulgarian Grigor Dimitrov who came from a set down to beat Marcos Baghdatis.