By Dion Nissenbaum, Nancy A. Youssef, Wall Street Journal–

The U.S. military is crafting plans that would keep nearly 1,000 forces in Syria, U.S. officials said, a shift that comes three months after President Trump ordered a complete withdrawal and is far more than the White House originally intended.

Protracted administration talks with Turkey, European allies and U.S.-backed Kurdish fighters have so far failed to secure an agreement to create a safe zone in northeastern Syria, part of Mr. Trump’s plan for leaving Syria.

The U.S. now plans to keep working with Kurdish fighters in Syria, despite Turkish threats to cross the border and attack the Kurds, the U.S. officials said. The proposal could keep as many as 1,000 American forces, spread from the north of Syria to the south, they said.

Once the last bastion of Islamic State is seized, the U.S. expects to shift its focus toward withdrawing hundreds of American forces, in keeping with what Mr. Trump originally ordered.

The evolving discussions represent a decisive shift away from Mr. Trump’s December directive to get all Americans out of Syria, a country he recently said was little more than “sand and death.”

His original decision to withdraw all of the more-than-2,000 U.S. troops from Syria triggered the resignation of Pentagon chief Jim Mattis and drew widespread concern that America was leaving the fight against Islamic State before it was really over.

Mr. Trump stood by his decision, but members of Mr. Trump’s national-security team urged the president to secure assurances that Turkish President Recep Tayyip Erdogan wouldn’t attack the U.S.-backed Kurdish fighters once America withdrew. Turkey has refused to do so.

Faced with pressure from all sides, Mr. Trump scrapped his original withdrawal order in February and decided to keep some U.S. troops in Syria.

The White House said then that the U.S. would keep 200 peacekeepers for a period of time. Administration officials said soon after that the number actually would be closer to 400, and that half of them would remain at a base in southern Syria that serves as an unofficial outpost meant to complicate Iran’s efforts to shuttle weapons to its Hezbollah allies in Lebanon.

U.S. military officials said the White House numbers weren’t based on Pentagon estimates. “The original number had no basis in military planning,” one U.S. military official said.

After The Wall Street Journal story appeared online Sunday evening, Gen. Joseph Dunford, chairman of the Joint Chiefs of Staff, issued a statement saying it was “factually inaccurate” to say the military was developing plans to keep nearly 1,000 troops in Syria.

“We continue to implement the president’s direction to draw down U.S. forces to a residual presence,” he said.

Mr. Trump also initially embraced the idea of shifting some U.S. forces to neighboring Iraq. But Baghdad questioned the idea after Mr. Trump said the Iraq-based U.S. troops would monitor Iran’s influence across the region.

The larger American presence addresses concerns about Islamic State’s ability to regroup. U.S. officials estimate the extremist group has between 15,000 and 20,000 armed fighters world-wide, including some operating as sleeper cells in Iraq and Syria.

The danger Islamic State still poses became clear in January when a suicide bomber targeted a restaurant in the Syrian town of Manbij, killing four Americans. The U.S. military wants a large enough force in Syria to carry out counterterrorism operations, American officials said.

U.S. officials said the exact number of Western troops that will remain in Syria is still being worked out. Mr. Trump could further constrain the military plans if he decides that having so many Americans stay in Syria isn’t worth the risk.

James Jeffrey, the top U.S. diplomat overseeing the global campaign against Islamic State, said the administration would keep pushing its policy goals in Syria, including a demand that Iran and its allies leave the country.

“We well understand that an American military presence—and the numbers and functions can go up and down—is a force for stability and collective security in the region,” he said on Friday.

One senior administration official made it clear that the U.S. presence in Syria would shrink.

“There will be a substantial withdrawal and final numbers are neither determined nor approved,” the official said.

As part of the developing plans, the Trump administration wants European allies to stay in Syria to continue training and support for the Kurdish-led Syrian forces that led the successful ground war against Islamic State, U.S. officials said. That is certain to anger Ankara, where Mr. Erdogan views the Syrian Kurdish fighters as a terrorist force intent on attacking Turkey.

Mr. Erdogan was the unexpected catalyst for Mr. Trump’s December withdrawal decision. He has pressed for creation of a safe zone in Syria to push the Kurdish forces away from Turkey’s border and create a place where Syrian refugees living in Turkey are able to go and start new lives.

But the U.S., Turkey and European governments have been unable to agree on who should secure that area. Leaders in Ankara have suggested that Turkish and American military forces work together, but the two sides have been unable to agree on a plan.

A second senior administration official described the talks with Turkey as constructive and said they were working to “set conditions for the voluntary return of refugees and internally displaced persons.”

The inability to reach an agreement on a safe-zone plan has increased the chances that such a zone may not be created at all. That could set the stage for Turkey to flout U.S. admonitions and launch a military assault on the Kurdish forces in Syria that could put American forces at risk.

While no European ally has yet to agree to the new U.S. plan, American officials said they were optimistic that the Europeans would eventually decide to stay.

“No one has been asked to have anything to do with any theoretical safe-zone mission,” the first senior administration official said. “Rather, all have been pitched to support core U.S. [counter-Islamic State] mission.”

Write to Dion Nissenbaum at dion.nissenbaum@wsj.com and Nancy A. Youssef at nancy.youssef@wsj.com