After his first meeting with Israeli Prime Minister Benjamin Netanyahu, Mr Trump told his visitor both sides would have to make compromises.
He also asked Mr Netanyahu to “hold back on settlements for a little bit”.
Mr Trump said it would ultimately be up to the parties themselves to reach a peace agreement.
At Wednesday’s joint press conference, Mr Trump was asked about his commitment to a two-state solution between Israel and the Palestinians, a longstanding bedrock of US policy.
A “two-state solution” to the decades-old conflict between Israelis and Palestinians is the declared goal of their leaders and the international community.
It is the shorthand for a final settlement that would see the creation of an independent state of Palestine within pre-1967 ceasefire lines in the West Bank, Gaza Strip and East Jerusalem, living peacefully alongside Israel.
The UN, the Arab League, the European Union, Russia and, until now, the US routinely restate their commitment to the concept.
“So I’m looking at two states and one state,” said Mr Trump. “And I like the one that both parties like. I’m very happy with the one that both parties like.
“I can live with either one. I thought for a while that two states looked like it may be the easier of the two.
“To be honest, if Bibi [Mr Netanyahu] and the Palestinians, if Israel and the Palestinians are happy – I’m happy with the one they like the best.”
Mr Trump was also asked about his election promise to move the US embassy from Tel Aviv to Jerusalem, which could have serious implications for any peace negotiations.
Media captionNetanyahu and Trump: What are their key priorities?
“As far as the embassy moving to Jerusalem, I’d love to see that happen,” Mr Trump said.
“And we’re looking at it very, very strongly. We’re looking at it with a great care, a great care, believe me. And we’ll see what happens.”
When he was asked about a two-state solution, Mr Netanyahu said he wanted to focus on “substance” and not “labels”.
“There are two prerequisites for peace,” said the Israeli prime minister. “First the Palestinians must recognize the Jewish state.
“Second, in any peace agreement, Israel must retain the overriding security control over the entire area west of the Jordan River.”
The Israeli prime minister said he believes reversing the “rising tide of radical Islam” was possible with Mr Trump in the White House.
Mr Netanyahu also name-checked Mr Trump’s Jewish son-in-law Jared Kushner – whose father, a New Jersey real estate tycoon, has been a top political donor to the Israeli prime minister.
Mr Trump has appointed Mr Kushner, who has no experience in diplomacy, to lead the effort to negotiate a Middle East peace agreement.