But the president’s position softened as videos of crew members extolling their captain made their way around social media. Still, it was unclear exactly where the president now stands on the reinstatement of Captain Crozier, and Mr. Esper’s decision not to immediately accept the recommendation that the captain be reinstated could reflect a fear of getting on the wrong side of his boss, officials said.

Admiral Gilday and James McPherson, the acting Navy secretary who succeeded Mr. Modly after he resigned, reached agreement late last week that the events leading to Captain Crozier’s letter pleading for help showed that he should not have been removed, officials said. They briefed General Milley on their findings on Tuesday.

It was unclear late Friday why the defense secretary had delayed the process. His spokesman, Jonathan Hoffman, had said earlier in the day that Mr. Esper was likely to back the Navy’s conclusion. Subsequently on Friday, Mr. Hoffman issued a statement that “after the secretary receives a written copy of the completed inquiry, he intends to thoroughly review the report and will meet again with Navy leadership to discuss next steps.”

Mr. Esper is usually closely aligned with Mr. Trump, and may want to make sure that the president will not reverse the process, as he did last year when he ordered the Navy not to punish a member of the Navy SEALs whose case had caught his attention.

Captain Crozier, who friends say is feeling better after he himself contracted the coronavirus, is in isolation in the distinguished visitors quarter on a Navy base in Guam. He is awaiting another test to confirm that he no longer has the virus, his friend said.

Representative Adam Smith, a Washington Democrat who leads the House Armed Services Committee, issued a statement on Friday calling for the captain to be reinstated. “While Captain Crozier’s actions at the outset of the health crisis aboard the T.R. were drastic and imperfect, it is clear he only took such steps to protect his crew,” he said. “Captain Crozier should be reinstated to his command immediately.”

Former Navy leaders echoed that sentiment. “The Navy leadership made the right call and Secretary Esper needs to support it,” said Sean O’Keefe, who was Navy secretary under President George Bush. “Captain Crozier made a decision to place his crew above himself and that’s a noble precedent.”