Defense and aerospace companies can be underrated long-term investments. A handful of power players dominate the industry, enjoying competitive advantages thanks to their constant innovation, deep pockets, and strong ties to the U.S. government and its allies.

They also benefit from the fact that America faces numerous (and varied) threats. At the moment, war and lesser conflicts are taking place in Europe and the Middle East. Meanwhile, emerging national economies (like those in BRICS) have created economic pressure on Western countries like the United States, which has long had tense relationships with some Eastern powers.

The unfortunate reality is that America's strength protects America but it also creates global tension, which means that defense spending will likely be a priority for the U.S. government for the foreseeable future:

US Government Defense Spending with Forecast Chart

US Government Defense Spending with Forecast data by YCharts

General Dynamics (GD -0.81%), Lockheed Martin (LMT -0.01%), and RTX (RTX -0.23%) are three of the world's six largest defense and aerospace companies. Their products and services span land, sea, air, and space, and they are poised to grow for decades to come as key partners in America's defense efforts.

The best part? You can own stock in all three for under $900.

Here is what you need to know about these three buy-and-hold defense stocks.

1. General Dynamics (trading around $300 a share)

Defense companies understandably depend primarily on government spending for revenue, but General Dynamics offers more diversification than most. Its aerospace unit builds private jets and provides aviation services to companies and high-net-worth clients. The company's marine division is the leading designer and builder of nuclear-powered submarines. Lastly, its combat and technologies segments build land vehicles, weapons systems, and software used for IT and mission control.

Politics can create volatility, primarily when politicians debate America's defense budget. The budget doesn't always go up, stagnating for periods at a time. That can impact companies like General Dynamics. Still, revenue and earnings have historically marched higher if you're patient enough.

GD Revenue (TTM) Chart

GD Revenue (TTM) data by YCharts

That seems poised to continue. Analysts believe General Dynamics will grow earnings by an average of 12% annually over the long term. This sets investors up for double-digit returns once you factor in the company's 1.9% dividend yield. Those looking for investment exposure to a little bit of everything should give General Dynamics a hard look.

2. Lockheed Martin (trading around $472 a share)

Investors might have seen the F-35 in the news for its potential $2 trillion lifetime program cost. It's probably fair to say that it is Lockheed Martin's most famous product. However, the defense behemoth builds many products across its business units, including jets and helicopters, naval ships, satellites and spacecraft, missile systems, and cybersecurity offerings. The company's space segment represents nearly a fifth of revenue, making the stock an excellent pick for long-term exposure.

While controversial, the F-35 program has become a cornerstone for America's defense, with a potential runtime through 2088. It arguably sets a high floor for Lockheed Martin's business, which should give investors confidence that it will grow for decades.

LMT Revenue (TTM) Chart

LMT Revenue (TTM) data by YCharts

Despite the F-35's presence, analysts are more cautious about Lockheed Martin's growth. Analyst estimates call for annualized growth of 4% for the next three to five years. That sets investors up for high-single-digit returns when factoring in the stock's 2.7% yield. Looking further out, it's hard not to like Lockheed Martin's space unit as a potential growth catalyst down the road. Investors can look at Lockheed Martin as a high-floor, lower-ceiling investment.

3. RTX (trading around $102 a share)

A 2020 merger between Raytheon Technologies and United Technologies formed RTX, the world's largest defense company with $71 billion in annual revenue. RTX has a massive footprint in the aviation sector. Its Collins Aerospace unit sells aircraft, components, and systems to military and commercial clients. At the same time, Pratt & Whitney is a separate unit and leading manufacturer of aircraft engines and auxiliary power units. Its Raytheon segment houses its military offerings, which include weapons, systems, and components for air, land, sea, and space.

The merger brought with it accounting adjustments and spinoffs that impacted GAAP earnings. However, revenue is at all-time highs, and analysts expect profits to boost back with earnings per share of approximately $5.39 this year. Long-term estimates peg earnings growth at 11% annualized over the long term, so the future looks bright for RTX and its shareholders.

RTX Revenue (TTM) Chart

RTX Revenue (TTM) data by YCharts

Like General Dynamics, RTX offers investors added diversity in commercial business. Pratt & Whitney's leadership in critical aircraft components is a wide-moat competitive advantage that should help the company achieve consistent performance over the years.