Williams, 39, is again seeking to tie Margaret Court's record of 24 Grand Slam titles. Williams won her 23rd at the 2017 Australian Open.
She was eliminated in the third round at Melbourne last year, and appeared destined for the same fate until the 19-year-old Potapova became unnerved.
Serving at 5-4, the young Russian held two set points but double-faulted five times and was broken. Potapova squandered another lead in the tiebreaker, committing unforced errors on the final three points.
The last was perhaps the best of the match, with Williams playing spectacular defence to extend a 21-shot rally that ended when a weary Potapova misfired on a forehand.
Another wild scramble two games later swung the match even more in Williams' direction and had her laughing before the rally ended. She chased down a drop shot at the net, retreated to retrieve a lob, and watched from near the backstop as Potapova smacked an overhead into the net. "I've still got the wheels," Williams said with a grin. "I wasn't playing my best. I started playingdefence — it was the one thing that kept me in the match."
Williams won despite losing serve three times and committing 31 unforced errors. "It was just a weird day," she said. "Sometimes these matches are really just about getting through them and forgetting them and moving forward. In the past, I wasn't able to do that because I was so hard on myself, and it would affect me in the future. I'm still learning."
Seeded 10th, she'll next face Belarusian Aryna Sabalenka, who matched her best Grand Slam showing by advancing to the round of 16 beating American Ann Li, 6-3, 6-1.
Sabalenka is the only woman among the top 16 seeds who has yet to reach a major quarter-final. Her best effort previously came when she earned a fourth-round berth at the 2018 US Open.
"I really want to play well in the Grand Slams, go as far as I can," she said. "I'm trying to come out in the big stadiums and show my best."
She did that by overpowering Li from the start, winning her first two service games at love and then breaking at love. Sabalenka held every serve and pounded 15 forehand winners.
Sabalenka, 22, has won 23 of her past 26 matches.
In other women's third-round play, third seed Naomi Osaka cruised through with a 6-3, 6-2 victory over 27th seed Ons Jabeur, No 14-seeded Garbiñe Muguruza defeated Zarina Diyas 6-1, 6-1, and No 19 Marketa Vondrousova beat Sorana Cirstea 6-2, 6-4.
In men's play, sixth seed Alexander Zverev thrashed No 32 Adrian Mannarino 6-3, 6-3, 6-1, while No 18 seed Grigor Dimitrov advanced when Pablo Carreno Busta retired trailing 6-0, 1-0.
- AP