Trump, in a meeting with Netanyahu at UN General Assembly, also said he wanted to unveil a peace plan in the next two to three months.
United Nations: US President Donald Trump said on Wednesday he wanted a two-state solution to resolve the Israeli-Palestinian conflict, the clearest expression yet of his administration's support for such an outcome.
The Trump administration has in the past said it would support a two-state solution if both sides agreed to it.
Trump, in a meeting with Israeli Prime Minister Benjamin Netanyahu at the United Nations General Assembly, also said he wanted to unveil a peace plan in the next two to three months.
"I like a two-state solution. That's what I think works best ... That's my feeling," said Trump.
Netanyahu has said any future Palestinian state must be demilitarized and must recognise Israel as the state of the Jewish people - conditions that Palestinians say show he is not sincere about peacemaking.
The United States' Arab allies are strong proponents of a two-state solution.
At a news conference in New York later on Wednesday, Trump said he would be open to a one-state solution if that was the preference of the parties themselves, a position he has previously stated.
"If the Israelis and the Palestinians want one state, that's OK with me. If they want two states, that's OK with me," he said. "I'm happy if they're happy."
Doubts have mounted over whether Trump's administration can secure what he has called the "ultimate deal" since December, when the US president recognised Jerusalem as Israel's capital and then moved the US Embassy there.
Trump said "it is a dream of mine" to secure an agreement before the end of his term in office, which ends in early 2021.
"I don't want to do it in my second term. We'll do other things in my second term," he said. "I think a lot of progress has been made."
Netanyahu said after meeting Trump he was "not surprised" at the US president's preference for a two-state solution for peace with the Palestinians, Israeli media reports said.
Jerusalem is one of the major issues in the Israeli-Palestinian conflict. Both sides claim it as a capital. Trump's move outraged the Palestinians, who have since boycotted Washington's peace efforts, led by Trump's son-in-law and adviser, Jared Kushner.
The Palestinians want to establish a state in the West Bank and the Gaza Strip and East Jerusalem. Israel captured those territories in the 1967 Middle East war and annexed East Jerusalem in a move not recognised internationally. It regards all of the city as its eternal and indivisible capital.
Nabil Abu Rdainah, a spokesman for Palestinian President Mahmoud Abbas, said: "The two-state solution means to us that we have a Palestinian state on the 1967 borders, with East Jerusalem as its capital. This is the only way to achieve peace."
Rdainah said the Palestinians wanted to resolve all the core issues of the Israeli-Palestinian conflict - which include borders, settlements, refugees, security and the status of Jerusalem - "according to United Nations resolutions."
Rdainah, speaking in Ramallah in the occupied West Bank, refused to be drawn further, saying Abbas would make the Palestinian position clear in his speech to the General Assembly on Thursday.
Asked what Israel might have to give up in return for the embassy's move to Jerusalem, Trump replied: "I took probably the biggest chip off the table. And so obviously we have to make a fair deal, we have to do something. Deals have to be good for both parties ... Israel got the first chip and it's a big one."