Mazar I Sharif:
On a brief visit to the Bagram airbase outside the capital Kabul, Trump served turkey to soldiers in a cafeteria, posed for photographs and delivered a speech after meeting Afghan President Ashraf Ghani.
"The Taliban wants to make a deal and we're meeting with them and we're saying it has to be a cease fire and... now they do want to do a ceasefire," he told reporters.
About 13,000 US troops remain in Afghanistan, 18 years after the United States invaded in the wake of the September 11, 2001 attacks.
"There's nowhere I'd rather celebrate this Thanksgiving than right here with the toughest, strongest, best and bravest warriors on the face of the earth," Trump, on his first trip to Afghanistan, told the troops. "I've just come from serving Thanksgiving dinner to some of you... and we had a good time."
Trump joked that he sat down and started eating mashed potato but was called away before he even tasted his turkey.
"I should've started with that instead of the mashed potatoes, I made a mistake," he said. "But I hope everyone enjoyed the fantastic meal, it certainly did look good and hopefully everyone can get some well-deserved rest this holiday."
The United States earlier this year reached a deal with Taliban insurgents to pull US troops from the country and wind down America's longest war in return for security guarantees.
But Trump made a shock move in September, describing the year-long talks as "dead" and withdrawing an invitation to the insurgents to meet near Washington due to the killing of a US soldier.
The Taliban refuses to negotiate formally with the Afghan government, but diplomatic efforts have continued to foster dialogue and plant the seeds of an eventual brokered peace deal.
"For a period of time we've been working to make a deal," Trump said. "We've made tremendous progress over the last six months... and at the same time we've been drawing down our troops."
Ghani thanked Trump for "putting limits on the type of peace that will ensure the gains of the past year and ensure your security and our security."
Afghanistan remains roiled by violence, and US presidents are still only able to make unannounced visits due to the security threat.
In Washington, Trump's relations with the US military leadership have badly soured over his repeated interference in high-profile discipline cases.
On November 15, Trump -- the commander-in-chief -- reversed the demotion handed down to Navy SEAL Edward Gallagher who was accused of war crimes but was found guilty of a lesser offense.
Trump said that Gallagher had been "treated very badly" by the navy, and ordered that he would not be expelled from the elite SEAL (Sea, Air and Land) force.