WASHINGTON — As President Trump signed a sweeping executive order on Friday, shutting the borders to refugees and others from seven largely Muslim countries, the secretary of homeland security was on a White House conference call getting his first full briefing on the global shift in policy.
Gen. John F. Kelly, the secretary of homeland security, had dialed in from a Coast Guard plane as he headed back to Washington from Miami. Along with other top officials, he needed guidance from the White House, which had not asked his department for a legal review of the order.
Halfway into the briefing, someone on the call looked up at a television in his office. “The president is signing the executive order that we’re discussing,” the official said, stunned.
The global confusion that has since erupted is the story of a White House that rushed to enact, with little regard for basic governing, a core campaign promise that Mr. Trump made to his most fervent supporters. In his first week in office, Mr. Trump signed other executive actions with little or no legal review, but his order barring refugees has had the most explosive implications.
Passengers were barred from flights to the United States, customs and border control officials got instructions at 3 a.m. Saturday and some arrived at their posts later that morning still not knowing how to carry out the president’s orders.
“The details of it were not thought through,” said Stephen Heifetz, who served in the Justice and Homeland Security Departments, as well as the C.I.A., under the previous three presidents. “It is not surprising there was mass confusion, and I expect the confusion and chaos will continue for some time.”
Stephen K. Bannon, the chief White House strategist, oversaw the writing of the order, which was done by a small White House team, including Stephen Miller, Mr. Trump’s policy chief. But it was first imagined more than a year ago, when Mr. Trump, then a candidate for the Republican nomination, reacted to terrorist attacks in San Bernardino, Calif., by calling for a “total and complete shutdown of Muslims entering the United States.”
In the months that followed, Mr. Trump’s campaign tried to back away from the proposal, which was seen by Democrats as over-the-top campaign rhetoric that would never be reality. Mr. Trump offered few details as the campaign progressed, and as president-elect he promised to protect the country from terrorists with only vague promises of “extreme vetting.”
But Mr. Bannon, who believes in highly restrictive immigration policies and saw barring refugees as vital to shoring up Mr. Trump’s political base, was determined to make it happen. He and a small group made up of the president’s closest advisers began working on the order during the transition so that Mr. Trump could sign it soon after taking office.
A senior administration official said that the order was drafted in cooperation with some immigration experts on Capitol Hill and members of the “beachhead teams” — small groups of political appointees sent by the new White House to be liaisons and begin work at the agencies.
James Jay Carafano, a vice president of the conservative Heritage Foundation and a member of Mr. Trump’s transition team, said that little of that work was shared with career officials at the Homeland Security Department, the State Department or other agencies.
There was “a firewall between the old administration and the incoming one,” Mr. Carafano said.
One reason, he said, is that when the Trump transition team asked pointed questions suggesting new policies to the career officials, those questions were swiftly leaked to the news media, generating negative stories. So the Trump team began to limit the information they discussed with officials from the previous administration.
“Why share it with them?” Mr. Carafano said.
R. Gil Kerlikowske, who served as commissioner of
Customs and Border Protection under former President Barack Obama, said that his staff had little communication with Mr. Trump’s transition team, who made no mention of a bar on entry for people from certain countries.
White House officials in the meantime insisted to reporters at a briefing that Mr. Trump’s advisers had been in contact with officials at the State and Homeland Security Departments for “many weeks.”
One official added, “Everyone who needed to know was informed.”
But that apparently did not include members of the president’s own cabinet.
Jim Mattis, the new secretary of defense, did not see a final version of the order until Friday morning, only hours before Mr. Trump arrived to sign it at the Pentagon.
Mr. Mattis, according to administration officials familiar with the deliberations, was not consulted by the White House during the preparation of the order and was not given an opportunity to provide input while the order was being drafted. Last summer, Mr. Mattis sharply criticized Mr. Trump’s proposed ban on Muslim immigration as a move that was “causing us great damage right now, and it’s sending shock waves through the international system.”
Customs and Border Protection officers were also caught unaware.
They contacted several airlines late Friday that were likely to be carrying passengers from the seven countries and “instructed the airlines to offload any passport holders from those countries,” said a state government official who has been briefed on the agency’s actions.
It was not until 3 a.m. on Saturday that customs and border officials received limited written instructions about what to do at airports and border crossings. They also struggled with how to exercise the waiver authority that was included in the executive order, which allowed the homeland security secretary to let some individuals under the ban enter the country case by case.
One customs officer, who declined to be quoted by name, said he was given a limited briefing about what to do as he went to his post on Saturday morning, but even managers seemed unclear. People at the agency were blindsided, he said, and are still trying to figure things out, even as people are being stopped from coming into the United States.
“If the secretary doesn’t know anything, how could we possibly know anything at this level?” the officer said, referring to Mr. Kelly.
At the Citizenship and Immigration Service, staff members were told that the agency should stop work on any application filed by a person from any of the countries listed in the ban. Employees were told that applicants should be interviewed, but that their cases for citizenship, green cards or other immigration documents should be put on pause, pending further guidance.
The timing of the executive order and the lack of advance warning had homeland security officials “flying by the seat of their pants,” to try to put policies in place, one official said.
By Saturday, as the order stranded travelers around the world and its full impact became clear, Reince Priebus, the chief of staff, became increasingly upset about how the program had been rolled out and communicated to the public.
By Sunday morning, Mr. Priebus had to defend the immigration ban on NBC’s “Meet the Press,” where he insisted that the executive order was rolled out smoothly. He also backpedaled on the policy and said that the executive order’s restrictions on entry to the United States would not apply to legal permanent residents “going forward.”
As White House officials also insisted on Sunday that the order had gone through the usual process of scrutiny and approval by the Office of Legal Counsel, the continuing confusion forced Mr. Kelly to clarify the waiver situation. He issued a statement making clear that lawful permanent residents — those who hold valid green cards — would be granted a waiver to enter the United States unless information suggested that they were a security threat.
But senior White House officials insisted on Sunday night that the executive order would remain in force despite the change, and that they were proud of taking actions that they said would help protect Americans against threats from potential terrorists.
That assertion is likely to do little to calm the public furor, which showed no signs of waning at the beginning of Mr. Trump’s second full week in the Oval Office.
Mr. Carafano said he believed that the substance of Mr. Trump’s executive order was neither radical nor unreasonable. But he said that Mr. Trump’s team could have delayed signing the order until they had better prepared the bureaucracy to carry it out.
He also said the president and his team had not done a good job of communicating to the public the purpose of the executive order.
“If there is a criticism of the administration, and I think there is, I think they have done a rotten job of telling their story,” he said. “It is not like they did not know they were going to do this. To not have a cadre of people out there defending the administration — I mean, really guys, they should have done this.”