US President Donald Trump sent a letter to his Turkish counterpart before Erdogan launched an incursion into Syria, urging him "don't be a tough guy" and "don't be a fool!"
The October 9 letter, released by the White House on Wednesday, came as Trump fought to control criticism of his decision to withdraw US troops from northern Syria, paving the way for a Turkish military operation.
Turkey invaded northern Syria five days ago to drive Kurdish-led forces away from the border, accusing the Kurds of being terrorists.
Kurdish forces in Syria have been longtime Western partners in the fight against the so-called Islamic State (IS).
"You don't want to be responsible for slaughtering thousands of people," wrote Trump, "and I don't want to be responsible for destroying the Turkish economy — and I will."
He went on to caution Erdogan: "History will look upon you favorably if you get this done the right and humane way. It will look upon you forever as the devil if good things don't happen."
"I will call you later," Trump signed off his letter.
The Turkish president said on Wednesday he will only end Turkey's offensive in northern Syria if Kurdish-led forces withdraw.
It would be the fastest way to end the conflict, he said, adding that he was not willing to negotiate on his position.
The US House of Representatives earlier on Wednesday voted overwhelmingly to condemn President Donald Trump's withdrawal of American forces from northern Syria.
Democrats and Republicans banded together and approved a nonbinding resolution, which states Congress' opposition to the troop pullback and says Turkey should cease its military action in Syria.
The measure said the White House should present a plan for an "enduring defeat" of IS.