The president spoke as he and Ms Haley met in the Oval Office, shortly after word came of her plans to resign.
"She told me probably six months ago", Trump told reporters, '"I want to take a little time off'".
Her most visible role, however, is likely to be remembered as pulling the US out of the U.N. Human Rights Council, which she described as a "cesspool of political bias" against the USA and Israel.
The announcement was news to many congressional Republicans involved in foreign policy matters, and some key US allies did not get advance word from Haley or the White House.
Joined by the former SC governor in the Oval Office, he invited her to come back in a different role. Haley and Trump tangled before he won the 2016 presidential race.
Trump said he would announce Haley's successor in the next two to three weeks, signalling that "many people" are interested in the job.
Haley, the former governor of SC, was among Trump's first appointments and was confirmed four days after he took the oath of office. Alas, Graham is "not interested" in a Cabinet spot, an aide told CNN.
A rookie to worldwide politics, the former SC governor was an unusual pick for to be United Nations envoy.
Haley, who has been one of Trump's most trusted advisers, would not confirm the report to Reuters when asked about it during a visit to the White House on Tuesday.
Ms. Haley said she had no plans to run for President in 2020.
"It has been an honor of a lifetime", Haley said of serving as United Nations ambassador.
Haley has pressed for a hawkish line on Iran, justified U.S. cuts to foreign assistance and earlier this year led the United States in bolting from the UN Human Rights Council, accusing it of bias against Washington and Israel. "You can have your pick", he said. "So I look forward to supporting the president in the next election", she said.
Trump wrote on Twitter that there would be a "Big announcement with my friend Ambassador Nikki Haley in the Oval Office" on Tuesday morning. She was re-elected in 2014.
As governor, she developed a national reputation as a racial conciliator who led the charge to bring down the Confederate flag at the Statehouse and guided SC through one of its darkest moments, the massacre at a black church.
South Carolina Republican Sen. The President lauded her accomplishments on issues ranging from North Korea to China at the United Nations, saying, "she got to know the players".