President Trump met with his top national security advisers Friday to consider a deal with the Taliban that could lead to the withdrawal of most U.S. forces from Afghanistan and the end of America’s longest military engagement abroad, U.S. officials said.

Mr. Trump in a tweet after the meeting said the U.S. is “looking to make a deal—if possible.”

Joining...