“In recent weeks, as the political environment has sharply changed, I have done significant reflection on what the corporate structural changes will require, and what it means for the global role I signed up for,” he said.
“Against this backdrop, and as we expect to reach a resolution very soon, it is with a heavy heart that I wanted to let you all know that I have decided to leave the company.”
He will be replaced by US general manager Vanessa Pappas on an interim basis, TikTok said. The move was first reported by the Financial Times.
Mr Trump claims that TikTok is a national security threat because it is owned by the Chinese firm ByteDance.
Earlier this month, the US president signed an executive order to block TikTok if ByteDance did not end the app’s US operations by the middle of September. A week later, he issued another order giving ByteDance 90 days to complete the deal.
In June, the company was also on the receiving end of a ban from the Indian government after it blocked 59 Chinese apps following a border clash between India and China.
Mayer wrote to the Indian government saying Beijing had never requested user data, nor would TikTok turn it over if asked.
ByteDance has been in talks to sell TikTok’s North American, Australian and New Zealand operations, which could be worth $25bn (£18.9bn), to companies including Microsoft Corp and Oracle, Reuters reported.
Mr Mayer only officially took up the role at TikTok on June 1.
TikTok said: “We appreciate that the political dynamics of the last few months have significantly changed what the scope of Kevin’s role would be going forward, and fully respect his decision. We thank him for his time at the company and wish him well.”
Zeen is a next generation WordPress theme. It’s powerful, beautifully designed and comes with everything you need to engage your visitors and increase conversions.