The Australian was beaten 6-2 6-4 in her quarter-final by Maria Sharapova, a two-time champion in Doha.
The day, though, belonged to Williams, who was in tears after her historic 3-6 6-3 7-5 victory over Petra Kvitova.
Williams, 31, will take over from Australian Open champion Victoria Azarenka as the world's best player on Monday, returning to the top spot for the first time in over two years.
Chris Evert at 30 was the previous oldest world No.1.
Williams was 4-1 down before reeling off six of the last seven games, taking the match with an ace down the middle.
Her relieved smile, heavenward gesture and tears in her moment of triumph gave lie to her earlier statement that the number one position no longer mattered.
"I am so sensitive nowadays - I am always crying, but I never thought I would be here again you know," said Williams in a reference to the pulmonary embolism from which she suffered in 2011, threatening her life as well as her career.
"When I was down I heard people cheering for me and I don't get that all the time. I never thought I would be number one again."
Williams, who faces Sharapova in the semi-finals, will be the world No.1 for a 124th career week - a total only bettered by Steffi Graf (377), Martina Navratilova (332), Evert (260), Martina Hingis (209) and Monica Seles (178).
Earlier, Australian Open champion Victoria Azarenka defeated Sara Errani 6-2 6-2.
The Belarusian's surprisingly emphatic win over the Italian means she has dropped a mere nine games in three matches.
Azarenka's semi-final will be a sequel to last year's contentious meeting with Agnieszka Radwanska.
The world No.4 from Poland came from 0-3 and 3-5 down in the second set to win 6-2 7-5 against Caroline Wozniacki, the former world No.1 from Denmark.
"She's a great fighter and I'm just happy to get through to the semi-finals again here," said Azarenka, who has established an affinity for the sea air, gentle winter sunshine and slowish hard courts in Qatar.
"I came here to practise before the Australia Open, and I shall be back here to do the same in December."