By Alana Wise

WASHINGTON (Reuters) - Republican presidential nominee Donald Trump on Sunday told Israeli Prime Minister Benjamin Netanyahu that if elected, the United States would recognize Jerusalem as the capital of Israel, the campaign said, marking a potential dramatic shift in U.S. policy on the issue.

During the meeting that lasted more than an hour at Trump Tower in New York, Trump told Netanyahu that under his administration, the United States would "recognize Jerusalem as the undivided capital of the State of Israel."

While Israel calls Jerusalem its capital, few other countries accept that, including the United States. Most nations maintain embassies in Tel Aviv.

Palestinians want East Jerusalem, captured by Israel in a 1967 war, as capital of the state they aim to establish alongside Israel in the West Bank and Gaza Strip.

During the closed-door meeting, the campaign said that Trump agreed with Netanyahu that peace in the Middle East could only be achieved when "the Palestinians renounce hatred and violence and accept Israel as a Jewish State."

According to a readout of the meeting from the campaign, the two discussed "at length" Israel's border fence, cited by Trump in reference to his own controversial immigration policies, which include building a wall on the U.S.- Mexico border and temporarily banning Muslims from entering the country.

Other regional issues, including the fight against Islamic State, U.S. military assistance to Israel -- "an excellent investment" -- and the Iran nuclear deal, which both parties have criticized, were also discussed.

(Reporting by Alana Wise; Editing by Bill Trott and Sandra Maler)