Not every stock rose last year. Consider these four -- Nike (NKE 0.19%), MarketAxess (MKTX 0.10%), Paycom Software (PAYC 1.24%), and The Hershey Company (HSY -0.53%) -- which fell between 10% and 42% in 2023. That stands in stark contrast to the S&P 500 index's 23% rise.

Despite these worrying drops, nothing changed dramatically for the worse regarding any of the four dividend growers' operations. This disconnect between declining share prices and each company's leadership position in its niche may create opportunities for investors focused on the long haul.

These companies are home to well-funded dividends that offer the potential to grow far into the future. Here's why these S&P 500 stocks are four of my top selections to buy in 2024 and hold forever.

1. Nike

With a total return north of 92,000% since its initial public offering (IPO) in 1980, Nike has an incredible track record of remaining the most dominant brand in footwear and apparel.

To help quantify just how powerful the Nike name is, consider that Kantar Brandz listed it as the 13th-most-valuable brand in 2022, ahead of businesses like Coca-Cola, Tesla, and Netflix. This top-tier brand power is noteworthy for investors. The companies in Kantar Brandz's top 100 each year have posted stock returns stronger than the S&P 500 by a score of 357% to 245% since 2006.

Best yet for investors, Piper Sandler's 2023 survey on U.S. teenagers' spending showed that Nike remained the far-and-away leader in footwear and apparel, with 61% and 35% of respondents calling the company their favorite for each segment. This robust mindshare among Gen Z shoppers signals that Nike's current struggles are temporary and should not be an ongoing problem as these young shoppers age and begin making more financial decisions on their own.

On the financial side, Nike pays a 1.4% dividend yield that only uses 40% of its net income, leaving a promising growth runway for investors seeking passive income. It's grown this dividend by 11% annually over the last five years. Nike promises to reward patient investors who are willing to wait out the currently unfriendly consumer spending environment that helped its stock slide 20% in the last year.

Thanks to its best-in-class brand, friendly cash returns to shareholders, and a rightsizing inventory that has dropped 17% from its 2022 highs, Nike looks like a premium business trading at the fair price of 25 times free cash flow (FCF).

2. MarketAxess

With its focus on bringing bond trading into the digital age, MarketAxess has delivered total returns above 1,700% since its IPO in 2004. However, even following this incredible run, the company's growth story should be far from over.

Despite this era of supercomputers and artificial intelligence, CEO Christopher Gerosa estimates that less than 40% of U.S. high-grade and high-yield bonds is traded electronically, like they are on MarketAxess's all-to-all platform. These figures drop even lower, to 5% or 7%, for emerging markets. With Gerosa and MarketAxess expecting electronic bond trading to mature and account for over 80% of trades for each bond group, the company's growth story could still be in its early chapters.

While this growth runway provides plenty of intrigue for investors over the long term, the subdued levels of volatility in today's markets continue to weigh on MarketAxess's financial results, sending its stock down 16% in the past year. Although I am a big fan of these calmer markets, this is not an excellent thing for MarketAxess specifically, as it thrives from the increased bond trading that usually occurs alongside higher levels of volatility.

With a 1% dividend yield that has grown by 12% annually over the past decade -- and that only uses 44% of the company's net income -- MarketAxess is happy to pay investors to wait for the inevitable turnaround in the electronic bond trading market. The company reports earnings on Jan. 31, so MarketAxess will soon provide us with some insights into the nature of this turnaround.

3. Paycom

Paycom provides cloud-based human capital management (HCM) tools such as talent acquisition and management, time and labor management, payroll, and human resources. It has become a 12-bagger in less than a decade since its IPO. After launching its automated and employee-guided payroll solution, Beti, in 2021, the company saw a dramatic decrease in payroll errors and omissions from its customers.

This is a great sign, right? Of course -- at least, in the long term. This new offering is a huge benefit to its customers and their happiness. But in the short term, this streamlining of its customers' payrolls has weighed on Paycom's growth rates, as it previously made money fixing these errors and omissions.

This trade-off between short-term pain and long-term opportunity is what makes Paycom so interesting today, especially with its stock down around 40% in the past year.

PAYC Chart

PAYC data by YCharts

Ultimately, this should prove to be a fantastic "problem" for Paycom. Beti's early success highlights why the company's offerings remain the most beloved among its customers in its HCM niche. With a new 0.8% dividend yield that management expects to continue raising annually -- and that only uses 26% of the company's net income -- Paycom could be a budding dividend growth story.

With its sales growing by 22% despite these nice-to-have headwinds, Paycom could quickly outgrow its price-to-earnings (P/E) ratio of 34.

4. Hershey

As the most profitable chocolatier and confectioner among its publicly traded peers -- on a return on invested capital (ROIC) basis -- The Hershey Company has recorded market-beating annualized returns of 13% since its 1978 IPO. Powered by its namesake Hershey brand and its ownership of the Reese's and Kit Kat brands, the company is home to three of the top five most-recognizable chocolate labels in the U.S.

Thanks to this widespread recognition and over 100 beloved brands, Hershey maintains around a 45% share of the U.S. chocolate market and a 30% share of the candy, mint, and gum (CMG) niche.

This combination of top-notch profitability, brand power, and industry leadership leaves Hershey uniquely well-positioned to survive threats like Mr. Beast's Feastables offerings and the rise of GLP-1 weight-loss drugs. It's home to a well-funded 2.3% dividend yield that is its highest since the 2020 crash and a P/E ratio of 21 that is at its lowest since 2019, following a 10% drop over the last year. I'll happily buy more of this beloved American brand at a discount for my daughter.