Boeing fired its chief executive officer Monday in a move intended to bring to a close the most tumultuous period in its 103-year history, marked by a bungled response to two fatal airplane crashes blamed on a flawed software program and poor oversight.

Aviation industry analysts said the sudden dismissal of Dennis Muilenburg, who had worked for Boeing for more than three decades, was a desperate attempt by the company to win back the trust of regulators and the public after crashes of its 737 Max aircraft led to the deaths of 346 people and accusations that Boeing had misled regulators and its customers.

Whether it would be enough was not immediately clear.

“Their credibility has been shredded,” said Sen. Richard Blumenthal (D-Conn.), a member of the committee that oversees aviation and a sharp critic of Muilenburg’s leadership. “They have to rebuild it. This firing can be a turning point to restoring and redeeming the company, but there has to be a management house cleaning that reflects a change in the culture of secrecy.”

Others noted that Muilenburg would be replaced as CEO and president by Boeing’s chairman, David L. Calhoun, who has served on Boeing’s board for a decade and has no engineering background.

In the short term, Calhoun would make a great leader because of his ability “to reassure the outside world and stabilize the situation,” said Richard Aboulafia, an aerospace analyst for the Teal Group. But he is an unlikely agent of dramatic change. “In an ideal world he’d have aerospace engineering, program management and commercial marketplace experience,” Aboulafia said. "This is not exactly a recipe for change.”

In a statement Monday, Boeing said "The Board of Directors decided that a change in leadership was necessary to restore confidence in the Company moving forward as it works to repair relationships with regulators, customers, and all other stakeholders. Under the Company’s new leadership, Boeing will operate with a renewed commitment to full transparency, including effective and proactive communication with the FAA, other global regulators and its customers.”

But restoring confidence among the public, Boeing’s suppliers, airlines and members of Congress won’t be easy. And it comes as the company must deal with the fallout of halting production of the flawed 737 Max airplane, ongoing scrutiny by the Federal Aviation Administration, and lawsuits brought by the families of victims who died in the crashes.

In the months since the crashes — one in October 2018 in Indonesia and the other in March in Ethiopia — revelation after revelation about the software’s development and approval led relatives of the crashes’ victims as well as members of Congress to angrily accuse Boeing of putting profits ahead of safety. Boeing, whose sales of commercial aviation aircraft have long been its cash cow, saw it’s bottom line take an $8 billion hit. On Dec. 16, it announced that it would temporarily suspend manufacture of the 737 Max beginning in January.

Rep. Peter A. DeFazio (D-Ore.), the chairman of the House Transportation Committee, said that Muilenburg’s departure was “long overdue.”

“Under his watch, a long-admired company made a number of devastating decisions that suggest profit took priority over safety,” said DeFazio, who has been leading an investigation into the crashes and the development of the Max aircraft. “I hope the decision to remove Muilenburg means that Boeing is also ready to mark a new chapter in its commitment to safety and accountability.”

In October, on the anniversary of the first crash, Democrats confronted Muilenburg with documents they had gathered as part of their own investigation into the crashes, raising new questions about what Boeing knew about the risks posed by the design of an automated feature that was intended to mimic the handling of an earlier version of the plane but, in fact, repeatedly forced the nose of the plane down in a way pilots struggled to override under certain circumstances.

Boeing had not revealed the details of the software’s operation to airlines in an effort to portray the Max version of the plane as not requiring additional pilot training.

Lawmakers took aim at Muilenburg directly, assailing him over his $30 million pay package and calling on him to resign. He did little to gain the confidence of the victims’ families, who were sitting just feet from him, repeating a line about his boyhood on an Iowa farm so many times that it eventually prompted groans from those watching in the room.

Aboulafia described the past year as a “cascading series of mistakes.” “It doesn’t get much worse," he said, "and it was made worse by very poor communication with the outside world: regulators, customers, Congress, suppliers, the general public. It was almost like a master class in bad communication.”

Muilenburg’s departure was effective immediately. According to a filing with the Securities and Exchange Commission a layoff could earn him as much as $39 million depending on the conditions of his removal. The company’s chief financial officer, Greg Smith, will serve as interim chief executive during the transition period.

Boeing’s stock jumped nearly 3 percent Monday, to close above $337 a share. Before Monday, Boeing’s share price had dropped 22 percent since the March crash, erasing about $52 billion of its market value.

On Friday, Boeing’s problems were compounded when, after a flawless launch to space, a Boeing spacecraft designed to fly NASA astronauts did not achieve the correct orbit when the capsule’s engines failed to fire as expected. The latest misstep forced the cancellation of the spacecraft’s planned mission to the International Space Station.

Muilenburg was present for the launch of the Starliner capsule, but made no public statement.

In a note to Boeing employees Monday morning, Smith thanked Muilenburg for his nearly 35 years at Boeing and wrote that he “gave his all to the company under extraordinarily difficult circumstances.”

“This has obviously been a difficult time for our company, and our people have pulled together in extraordinary ways,” Smith wrote. “Over the next few weeks as we transition to new leadership, I am committed to ensuring above all that we meet the needs of our stakeholders — especially our regulators, customers and employees — with transparency and humility.”

The FAA issued a statement Monday saying Boeing informed the agency of Muilenburg’s departure and reiterated that it is following no set schedule for when the Max will be cleared to fly again.

“The FAA continues to follow a thorough process for returning the Boeing 737 MAX to passenger service,” the agency’s statement said. “We continue to work with other international aviation safety regulators to review the proposed changes to the aircraft. Our first priority is safety, and we have set no timeframe for when the work will be completed.”

“We expect that Boeing will support that process by focusing on the quality and timeliness of data submittals for FAA review, as well as being transparent in its relationship with the FAA as safety regulator.”

In a statement, Michael Stumo, whose 24-year-old daughter Samya Rose Stumo was killed in one of the 737 Max crashes, said that Muilenburg’s resignation “is a good first step toward restoring Boeing to a company that focuses on safety and innovation. Now that it’s known what he and top Boeing officials knew, yet ignored, prior to the crashes, it has become clear how the company eroded in quality over the years.”

Robert A. Clifford, an attorney representing the families suing the company, said Boeing’s board “does not deserve a ‘pat on the back’ for this decision. In fact, their leadership decisions empowered Muilenburg and the company to create a culture where profits were put ahead of the safety of the global traveling public.”