Target (NYSE:TGT) shareholders got some positive news recently: On the back of a stronger-than-expected second-quarter earnings report, the stock surged over 3.2% the following day, and is now up over 30% on the year, breaking above levels not seen since 2015. 

Over the past few years, retail stocks have generally struggled, as they adapt (or attempt to adapt) to a world of lower foot traffic and greater e-commerce penetration. Investors obviously think Target is now back on the right, but I still think there are reasons to be cautious.

The home section of Target including tables with tablecloths and other home accessories.

Is Target's sales growth for real? Image source: Target.

Reason to buy: This market loves sales ...

Target's stock has largely risen over rejuvenated sales growth and traffic -- not just a bit of increased traffic but "an unprecedented amount" as management put it. Traffic was up 6.4% in the second quarter, the highest traffic growth figure since 2008. Comparable-store sales climbed 6.5%, the highest figure since 2005. Comp sales grew across all five core product segments, including both e-commerce and the physical stores -- same-store sales for Target stores were up 4.9%, while e-commerce comps grew 41%.

The reason behind the surge? CEO Brian Cornell explained:

Well-run retailers with strong balance sheets that generate cash that they can invest back into their business are winning right now. And there are, obviously, others right now that can't afford to invest in their store experience or build capabilities or drive differentiation. And they're giving us share.

Target has been quite aggressive pursuing sales, buying same-day delivery service Shipt earlier this year, lowering prices, opening smaller-format stores in denser urban markets, and rolling out private-label brands.

Reason to sell: ... but at what cost?

Not everything was sunshine and rainbows, however. Target has had to invest aggressively in order to keep up with e-commerce giant Amazon and a rejuvenated Walmart. That could potentially pressure margins going forward, and the current quarter did in fact show some erosion. Gross margin fell 10 basis points, while operating margin fell 30 basis points to 6.3%. Operating profits grew 3.6%, just over half the overall sales growth rate.

While that's not the end of the world, and it has in fact been Target's strategic plan to go after market share, investors have to weigh how much margin erosion may be ahead. Remember, Target is not the market leader trying to distance itself from potential challengers -- it's the eighth-largest retailer in the U.S., trying to catch up to established, formidable businesses with scale of their own.

One must also consider that the economy overall exhibited really strong growth last quarter. In fact, while Target's growth was impressive, it's really just in line with overall U.S. retail sales, which grew 6.4% year over year in July. We're still less than a year into the tax cuts, and no one really knows if current strength is a one-off "sugar high" or if growth has reaccelerated on a more permanent basis. So while Target no doubt had a good quarter, one has to wonder how much better it's really doing than the average big box retailer.

Target has also benefited mightily from the misfortunes of others, such as Toys R Us, which filed for bankruptcy earlier this spring. On the conference call with analysts, Target's management admitted that turn of events boosted the toys segment last quarter. While that category may in fact experience a permanent uplift, the growth in the toys category might be unusually high in 2018. Once all of the remaining struggling retailers fall by the wayside, that low-hanging fruit will have been plucked.

Of course, 2018 is shaping up to be a record year for retail bankruptcies, potentially exceeding 2017's previous record. So there still may be more incremental retail dollars for Target to pick up this year.

Cautious though congratulatory

Don't get me wrong, I applaud Target's management for making these aggressive moves. However, as an investor currently looking at Target, one needs to consider that this might be as good as it gets. Retail is a notoriously difficult and competitive business, and with Target's stock back at multiyear highs, I'd be cautious.

John Mackey, CEO of Whole Foods Market, an Amazon subsidiary, is a member of The Motley Fool's board of directors. Billy Duberstein owns shares of Amazon. His clients may own shares of some of the companies mentioned. The Motley Fool owns shares of and recommends Amazon. The Motley Fool has a disclosure policy.