Swiatek, who had never lost to a qualifier at a major before, won just three of the last 16 games.
Olympic champion Zheng battled her way through qualifying amid a post-injury career slump and has recaptured her top form in New York, getting the best of an opponent who had led 7-1 in their head-to-head.
"I start the match not so well and after little by little I found my rhythm," said China's Zheng, whose chronic right elbow injury stunted her career and forced her to undergo surgery last year.
"I just focused point by point and little by little I started to play better tennis."
She next plays second seed Elena Rybakina, who defeated Naomi Osaka 6-1 6-4 later on Monday (Tuesday AEST).
Rybakina, who won Wimbledon in 2022 and this year's Australian Open, cleared another big hurdle in her bid to win a third grand slam title by outclassing the 13th-seeded former champion and left the Kazakh one match win away from becoming world No.1 for the first time.
"If I serve as well as I did today, I think I have all the chances. I'll try my best. Hopefully it's going to go my way," Rybakina said.
Zheng, meantime, appears to do her best work with her back against the wall, recovering from 5-0 down in the deciding set of her third round match with Madison Keys, and she found the magic again at Arthur Ashe Stadium.
The current world No.121 saved three set points to the increasing frustration of 2022 champion Swiatek, who lost the same match-up in the Olympic semis.
Fifth seed Mirra Andreeva also fought back to progress, beating Anastasia Potapova 5-7 6-4 6-3 to extend her deepest run at the US Open.
The 19-year-old was 5-3 up in the third when Austrian Potapova went down with a leg injury, putting a disappointing end to an otherwise competitive affair.
"She's my good friend and ... seeing her fall like this, it's not easy," said Andreeva.
"It's not the way obviously you want to finish the match."
The Roland Garros winner will next play Coco Gauff, who saw off fellow American Iva Jovic 6-1 6-4 to stay on course for a third grand slam title.
Fourth seed Gauff, who captured her first major title at Flushing Meadows in 2023, delivered a dominant display and a quarter-final featuring the last two French Open champions awaits.
Australia's involvement in women's action is over after Storm Hunter, Maya Joint and Ellen Perez were ousted from the doubles.
Hunt and American Desirae Krawczyk, the 13th seeds, lost their third-round clash against top-ranked pair Taylor Townsend and Katerina Siniakova 7-6 (8-6) 6-4.
10th seeds Perez and Demi Schurrs of the Netherlands' were beaten 7-5 6-3 by Belgian duo Elise Mertens and Diana Schnaider, the eighth seeds, while 14th seeds Joint and Taiwan's Hao-Ching Chan lost 6-4 6-4 to fourth-ranked duo Jelena Ostapenko and Su-Wei Hsieh.
With AAP.