WASHINGTON -- The vast protests gripping Cairo put President Obama in a position both awkward and familiar, recalling the winter of 2011, when he grappled with what to do about another embattled Egyptian president, a restive military, and angry young Egyptians quick to see a meddling American hand in their political drama.
Then, as now, Mr. Obama has moved gingerly, placing a call to President Mohamed Morsi late Monday evening with a message not unlike the one he delivered to his predecessor, Hosni Mubarak, two and a half years earlier: Exercise restraint and allow the protesters to express their views peacefully.
American officials have broached the possibility of Mr. Morsi's calling early elections, a senior administration official said, but added, "We are not pushing it as a preferred U.S. option." Other options include Mr. Morsi's replacing his cabinet or ousting an unpopular prosecutor.
But officials and outside analysts caution that the United States has little leverage over either the Morsi government or those demanding his ouster. With neither side open to bargaining, the administration is essentially a bystander in what some experts characterize as a do-or-die struggle for control of the Egyptian state.
The White House acknowledged as much in its description of Mr. Obama's phone call with Mr. Morsi. "As he has said since the revolution, President Obama reiterated that only Egyptians can make the decisions that will determine their future," it said in a statement.
The lack of American influence did not prevent a flurry of American phone calls. Secretary of State John Kerry spoke to the Egyptian foreign minister, Mohamed Kamel Amr, who in a sign of the quickening pace of events had already submitted his resignation to Mr. Morsi.
The United States is also keeping open channels to the military, with which it has closer ties than with the civilian government. The Supreme Council of the Armed Forces has warned Mr. Morsi to meet the demands of protesters or face military intervention.
Gen. Martin E. Dempsey, the chairman of the Joint Chiefs of Staff, telephoned his counterpart, Lt. Gen. Sedky Sobhi, the Egyptian military's chief of staff, on Monday morning, officials said. They declined to describe the content of the discussion.
News reports in Egypt indicated that Defense Secretary Chuck Hagel also phoned his Egyptian counterpart, but officials in Washington declined to confirm any involvement in the growing crisis by the Pentagon chief, who visited Cairo in late April.
Mr. Obama first got to know Mr. Morsi during the bombings and airstrikes in Gaza last year, when the Egyptian president, then newly elected, played a role in brokering a cease-fire between Israel and Hamas. But the good will soured after Mr. Morsi issued a presidential edict putting his decisions beyond the reach of the courts.
The American response to Egypt's latest crisis has been complicated by the fact that until Tuesday, Mr. Obama and Mr. Kerry were out of the country. Mr. Obama called Mr. Morsi from Tanzania, the last stop of his weeklong African trip.
In the call, the White House said, the president expressed concern about violence during the demonstrations, particularly sexual assaults against women. He also urged Mr. Morsi to warn his supporters in the Muslim Brotherhood not to engage in violence.
"The United States is committed to the democratic process in Egypt and does not support any single party or group," Mr. Obama told Mr. Morsi, according to the White House. The statement said, "He stressed that democracy is about more than elections; it is about ensuring that the voices of all Egyptians are heard and represented by their government."
The studied neutrality of the language is meant to convey that the United States is not backing Mr. Morsi or the Muslim Brotherhood. But that message has been lost on the protesters, some of whom are wielding placards with images of Mr. Obama and the American ambassador to Cairo, Anne Patterson, defaced by black X's.
"People are going to be very sensitive to how they perceive the American role," said Tamara Cofman Wittes, director of the Saban Center for Middle East Policy at the Brookings Institution. "If Morsi stays in office or doesn't stay in office, there are going to be those who perceive a U.S. role."
Ms. Wittes, a former State Department official, said the United States was handicapped by the perception among many Egyptians that it embraced Mr. Morsi too quickly after he was elected president, and then did not object to his questionable early moves, like appointing a cabinet with no representatives from the opposition parties.
The military's ultimatum to Mr. Morsi is particularly troubling to the White House, she added, because when the military seized control of Egypt after the ouster of Mr. Mubarak, the United States took pains to persuade the generals to step out of politics, and stay out.
The United States gives Egypt $1.3 billion a year in military aid, but there is no sign the administration is using that as a form of pressure. In May, Mr. Kerry cited national security as a reason to waive restrictions put in place by Congress to prevent the aid from flowing to Egypt if it did not make progress with democratic reforms. And the $250 million in nonmilitary aid from the United States is not enough to matter.
"We just don't give them enough cash," Steven A. Cook, a senior fellow for middle eastern studies at the Council on Foreign Relations, said. "We're sort of caught by our sunk cost in Egypt."
The White House, Mr. Cook said, was hemmed in by its response to the last Egyptian uprising, when Mr. Obama was faulted for sticking too long to a dictator, and then promised that he would work with any democratically elected successor to Mr. Mubarak.
As the crisis deepened, the parallels to 2011 were striking. White House officials broke from meetings Tuesday evening to watch a televised address to the Egyptian nation by Mr. Morsi. His message, like the one Mr. Mubarak delivered in a similar TV appearance, was defiant.
Thom Shanker contributed reporting.world
This article originally appeared in The New York Times.