The incident occurred on social media, where Townsend posted videos of local dishes from China that included frogs and turtles. In the clips, she joked that she needed to "talk to HR" about the quality of the food.
The joke quickly sparked reactions, not least since the USA is meeting Kazakhstan in the Billie Jean King Cup, the women's equivalent to the Davis Cup, in Shenzhen, China, this week.
On Wednesday, the American took to social media and Instagram again - this time to back down and apologize.
"I just wanted to come here and apologize sincerely, from the bottom of my heart," said Townsend and continued:
"I have had nothing but fantastic experiences here and in the tournament. Everyone has been so kind and generous. And what I said did not reflect that at all. There are no excuses, no words. For my part, it's about me having to get better."
It's the second time in a short while that Townsend ends up in the hot seat. During the US Open in August, she ended up in conflict with the Latvian Jelena Ostapenko, who according to Townsend should have said that she "lacked education and class" after their meeting in the second round.