How much money will you need in retirement? Probably more than you think, since it'll take about $1 million to generate $40,000 in retirement income you can count on for years. But don't fret: You don't have to take on a bunch of risky investments and put your entire retirement savings at risk to reach your retirement goals. 

A better way? Invest in a handful of strong companies with solid long-term prospects, and hold them for the long term.

Some may not do as well as hoped, but the ones that do really well can more than make up for the stragglers. Three that should be on your list of buy and hold for the long term include construction and infrastructure engineering services company NV5 Global Inc (NASDAQ:NVEE), healthcare property owner Caretrust REIT Inc (NASDAQ:CTRE), and payments giant Mastercard Inc (NYSE:MA)

Older man sitting on the floor smiles as money falls around him.

Image source: Getty Images.

These three companies are as different from one another as it gets, but they share a very important trait that makes them excellent stocks to buy now and hold for years: Major trends are setting them up for potentially decades of growth. 

Three huge trends shaping the future

NV5, Caretrust REIT, and Mastercard couldn't be more different. But huge growth in global infrastructure spending, the doubling of America's retirement population, and the acceleration of electronic payments around the world are major trends with multi-decade implications. 

Two construction workers oversee a work project.

Image source: Getty Images.

NV5 Global, for instance, is positioned to profit from decades of increased global infrastructure investment. As I wrote back in July, it's estimated that the United States needs to invest almost $800 billion per year by 2040 to support domestic infrastructure needs.

Global annual infrastructure spending needs to be a staggering $3.3 trillion over that period -- an increase of $800 billion from current levels. With trailing annual revenues of $270 million, NV5 Global is a drop in the global infrastructure ocean, but a fast-growing one.

Since 2014 alone, the company has grown revenues more than threefold. That could be merely the tip of the iceberg in decades to come. 

A physical therapist assists a senior with an exercise.

Image source: Getty Images.

Caretrust REIT, like NV5 Global, is a small company when compared to many of its competitors. But also like NV5, that small size could pay off with big growth in an industry that's going to have to grow in coming decades. Over the next 20 years, the 65-plus population in the U.S. will double to more than 80 million, far outpacing the current capacity of senior healthcare and housing facilities.

Caretrust has already experienced strong growth since being taken public in 2012, having acquired nearly 100 senior housing, skilled nursing, and rehab facilities, more than doubling its size. Considering that the baby boomer retirement trend will only accelerate over the next 15 years, Caretrust's best days could be ahead of it. 

For Mastercard, it may be surprising to learn that electronic payments is a huge global growth industry. While we use credit and debit cards for almost all of our daily transactions in developed countries, on a global basis, 90% of transactions are still cash based. But that's changing quickly. The growth of the global middle class is on track to add more than 1 billion new consumers over the next couple of decades, while the internet and mobile devices are making electronic payments viable in much of the world where cash was not just king, but a monopoly. 

Customer uses Mastercard with mobile payment at a coffee shop.

Image source: Getty Images.

Mastercard will almost certainly be one of the big winners. It already has a huge market position, with a payments-processing network already in place that's trusted by thousands of financial institutions and tens of thousands of merchants worldwide. In addition, it has deep relationships with card-issuing banks, and one of the most recognized names -- and logos -- in the payments industry. The odds are very much in Mastercard's favor that this should help it deliver double-digit profit growth for years to come. 

Make them part of a diverse portfolio, then hold them for decades

I own all three of these companies in my retirement portfolio, having bought them for the same reasons described above. For the companies to fulfill their potential, they'll need many years to invest in their businesses and grow. That will take a lot of patience for investors, and most importantly, the willingness to stay out of the way and sit tight, in good markets and bad. 

There'll be bull and bear markets over the coming decades. There'll be strong economies and recessions, too. But if you truly want to retire a millionaire, the bottom line is this: In 20 years or more, the industries these companies participate in will be much, much bigger. Investing in the three companies above as part of a diversified portfolio -- and then holding your shares for many years to come -- could go a long way toward retiring with the wealth you want.

Jason Hall owns shares of CareTrust REIT, Mastercard, and NV5 Global. The Motley Fool owns shares of and recommends Mastercard. The Motley Fool has a disclosure policy.