With a record price tag — potentially in the hundreds of billions of dollars — the jet is likely to become a target for budget cutters. Reining in military spending is on the table as President Obama and Republican leaders in Congress look for ways to avert a fiscal crisis. But no matter what kind of deal is reached in the next few weeks, military analysts expect the Pentagon budget to decline in the next decade as the war in Afghanistan ends and the military is required to do its part to reduce the federal debt.

Behind the scenes, the Pentagon and the F-35’s main contractor, Lockheed Martin, are engaged in a conflict of their own over the costs. The relationship “is the worst I’ve ever seen, and I’ve been in some bad ones,” Maj. Gen. Christopher Bogdan of the Air Force, a top program official, said in September. “I guarantee you: we will not succeed on this if we do not get past that.”

In a battle that is being fought on other military programs as well, the Pentagon has been pushing Lockheed to cut costs much faster while the company is fighting to hold onto a profit. “Lockheed has seemed to be focused on short-term business goals,” Frank Kendall, the Pentagon’s top weapons buyer, said this month. “And we’d like to see them focus more on execution of the program and successful delivery of the product.”

The F-35 was conceived as the Pentagon’s silver bullet in the sky — a state-of-the art aircraft that could be adapted to three branches of the military, with advances that would easily overcome the defenses of most foes. The radar-evading jets would not only dodge sophisticated antiaircraft missiles, but they would also give pilots a better picture of enemy threats while enabling allies, who want the planes, too, to fight more closely with American forces.

But the ambitious aircraft instead illustrates how the Pentagon can let huge and complex programs veer out of control and then have a hard time reining them in. The program nearly doubled in cost as Lockheed and the military’s own bureaucracy failed to deliver on the most basic promise of a three-in-one jet that would save taxpayers money and be served up speedily.