Williams had been hoping to take an outright lead in overall Grand Slam titles with 24, but fell agonisingly short in a three-set epic on Rod Laver Arena. The 38-year-old lost 4-6, 6-7 (7-2), 5-7 to China's world number 29 in a match that lasted for over two hours and 40 minutes.
After winning the opening set and going up a break in the second, Wang allowed the eighth-seeded American to stage a remarkable comeback to take the match into the decider.
The third set was tense and closely fought for 11 games until the 23-time Grand Slam champion blinked first at the most crucial moment.
Serving to stay in the match, Williams went down 15-40 but fought back to deuce before Wang converted her third match-point opportunity to advance to the fourth round of the Australian Open.
Williams was looking to break Margaret Court's Grand Slam tally of 24 but she will now have to wait.
Her last Grand Slam title came in Melbourne in 2017. Since giving birth to daughter Alexis Olympia later that year, the American legend has gone on to contest seven Slams and reached the final on four occasions, but that 24th major crown remains elusive.
In the fourth round for the first time, Wang will take on Tunisia's Ons Jabeur, who defeated retiring Caroline Wozniacki, 7-5, 3-6, 7-5 earlier in the day to advance.
( With inputs from IANS )