Not many retailers can claim to be reliable dividend payers. That's because the industry is highly competitive and characterized by tiny profit margins. Retailers must also endure sales pressures during those inevitable downturns in consumer spending that make it harder to maintain positive earnings consistently.

As a result, when you see a retailer that's been steadily boosting its dividend for decades, you've likely found an unusually strong business. Not only have these companies maintained profitability through a wide range of selling conditions, but they've effectively managed their capital to protect shareholders' returns.

Walmart (WMT -0.08%) and Target (TGT 0.18%) are two rare examples of safe dividend payers in the retail space. Between them, they've hiked their annual payouts for over 100 years. But only one of them is an excellent candidate for an income investor's portfolio right now.

Why you should consider buying Walmart stock

Walmart's business is on the upswing even as consumers pull back their spending in several budget areas. Sales in the most recent quarter rose 6%, including a 24% spike in e-commerce revenue. Compare that to Target, which last reported 10% lower digital sales, and you can see that the retailer is positioned well for the current spending environment. Walmart also beat its rival in the customer traffic metric, up 3% in the core U.S. market compared to Target's 5% decline.

Walmart's finances are excellent, meanwhile. Gross profit margin ticked higher last quarter and operating income is up 11% through the first half of 2023. These wins helped convince management to raise its fiscal year outlook thanks to solid demand in both groceries and discretionary categories like home furnishings. "Food is a strength," CEO Doug McMillon told investors in mid-August, "but we're also encouraged by our results in general merchandise."

Sure, Walmart's dividend yield is much lower than Target's (1.4% compared to 3.9%). And Target has a slightly longer track record of consecutive dividend raises than its larger peer. Walmart has 50 consecutive annual hikes under its belt while Target's streak is sitting at 52 years.

Why you might want to avoid Target stock

Target stock doesn't seem nearly as appealing right now. The retailer's customer traffic levels decelerated in the most recent quarter, illustrating a key risk in its strategy of selling more consumer discretionary products like home furnishings. Walmart and Costco have each managed to keep traffic rising in this period due to their strength in the essentials like groceries.

Target is making progress in responding to the slowdown. Inventory was down 17% last quarter, including a 25% drop in those slow-moving niches. These successes helped the company protect profit margins compared to last year even though sales trends were worse than expected in Q2.

Yet management lowered its sales and earnings outlook this past quarter, in contrast with Walmart's upgrade. Target also issued a wide forecast range that implies that management doesn't have a lot of clarity around demand trends right now. That's a difficult position to be in just as you're making commitments on inventory heading into the holiday shopping crush.

Target's stock valuation reflects a lot of this bad news. The price-to-sales ratio has dipped to below 0.5 compared to 0.8 earlier in 2023. Yet most investors will happily pay the premium for Walmart right now, which is valued at 0.7 times sales and has a much clearer path toward earnings growth this year and beyond.