“I am calling on the whole world: never sell your democratic will in return for petty dollars,” he said in a televised speech in Ankara.
Trump threatened to cut funding to countries that backed the motion to be voted on Thursday at the UN General Assembly.
The US decision on December 6 to recognise the city as Israel’s capital broke with international consensus and unleashed protests across the Muslim world, prompting a flurry of appeals to the United Nations.
At an emergency session, the UN General Assembly will decide Thursday on a draft resolution reaffirming that Jerusalem is an issue that must be resolved through negotiations and that any decision on its status has no legal effect and must be rescinded.
The measure was sent to the General Assembly after it was vetoed by the United States at the Security Council on Monday, although all other 14 council members voted in favour.
Trump warned that Washington would closely watch how nations voted, suggesting there could even be reprisals for countries that back the motion which was put forward by Yemen and Turkey on behalf of Arab and Muslim countries.
Erdogan accused Trump of making “threats”.
“How do they call America? The cradle of democracy. The cradle of democracy is seeking to find will in the world that can be bought with dollars,” he said.
“Mr Trump you cannot buy with dollars Turkey’s democratic will. Our decision is clear,” he said.
Erdogan said he believed that “the world will teach a very good lesson to America today (Thursday).”