One way to separate great companies from mediocre ones is to see how they're faring as tailwinds die down and they face tough year-over-year comparisons.

Home Depot (HD 0.86%) knew it would be in such a situation in this year's first quarter after a 33% year-over-year increase in sales last year. It also knew in January, when it gave a first outlook for 2022, that it would be dealing with supply-chain issues, inflation, and other macroeconomic changes.

It didn't know that with a new CEO and several strategic initiatives, it would crush its first-quarter guidance. But this great company, with its robust sales and top dividend, is supercharged for 2022.

Beating first-quarter guidance

Home Depot is the biggest home-improvement company in the world with more than 2,300 stores, most of them in the U.S. It took in nearly $152 billion in trailing 12-month sales -- and in 2022's first quarter, sales increased 3.8% year over year to $38.9 billion while earnings per share rose 6% to $4.09.

A Home Depot associate arranging flowers.

Image source: Home Depot.

For all of 2022, management had originally guided for a "slight" increase in sales, and it has now raised that to 3% growth in both total sales and same-store sales (or comps). Some of its sales beat has to do with its size, which gives it leverage when dealing with suppliers and supply chain issues. Chief Financial Officer Richard McPhail said the company's "in-stock position ... is the healthiest it has been since the pandemic began."

It also has more hands on deck and systems in place to organize solutions to supply challenges, and it says it is benefiting from a generally strong economy, where customers trade up for premium products.

All in all, a variety of factors led to the company's recent success,  and it's interesting to see how seemingly small shifts play out against the backdrop of a large company. Comps increased 2.2%, combining an 11% increase in average ticket amount and an 8.4% decrease in transactions. Average ticket growth was mostly due to inflation and demand for new products, and the decline in transactions was due to spring's late start this year and measuring up against strong sales last year as a result of stimulus checks. 

Why the future looks bright

What comes across from the broader discussion is that customers have money and they want to spend it. CEO Ted Decker said, "We believe that the medium to longer-term underpinnings of demand for home improvement have never been stronger." Some customers are trading up, and people who have money to spend are doing so. Large purchases, or those over $1,000, increased 12.4% over last year.

Pro sales were also stronger than do-it-yourself (DIY), which is part of the larger pattern of shoppers with heavy wallets hiring pros to do the job, although DIY was strong as well. Several pro categories, such as building materials, grew by double digits, and pros are saying they have a backlog of projects.

New products are also a growth catalyst. New technology (that is often more environmentally friendly) is driving innovation, and the pipeline is robust. At a recent Home Depot exhibition, new products made up 90% of the collection. Enhanced digital capabilities also simplify the shopping process and drive spending.

Sharing with shareholders

Home Depot has been paying a dividend since 1987, but it hasn't raised it annually for 25 years, so it's not on the Dividend Aristocrat list yet. It has raised it, though, for the past 12 years consecutively.

Home Depot stock is down 25% year to date, and at the current price, its dividend yields 2.3%. It has a low payout ratio of 42% as it keeps most of its cash to funnel it back into growth initiatives.

Shares are trading at less than 19 times trailing 12-month earnings, making Home Depot stock very cheap, and investors can enjoy a reliable, above-average dividend as they grow their money.