Target saw a surge of shoppers head to its stores and website during the 2018 holiday season, a sign that its investments in store remodels and delivery services are paying off, and an early sign that consumers across the U.S. spent more on gifts this year.

The retailer said Thursday that sales at its stores and website operating for at least 12 months climbed 5.7 percent this past holiday season. That compares with growth of 3.4 percent a year ago and surpasses some analysts' expectations.

But Target shares ended the day down about 3 percent on the heels of a slew of other retailers including Macy's and Kohl's reporting more disappointing holiday sales. Expectations for the retail industry have been high — with strong consumer confidence and low unemployment in the U.S. making a healthy backdrop to operate in. For some, though, sales growth is starting to decelerate.

Based on Thursday's results, Target said it is maintaining its profit outlook for the fourth quarter and fiscal 2018. It also announced the retirement of CFO Cathy Smith among some management changes.

Overall, CEO Brian Cornell said he's "very pleased" with Target's performance during November and December, in stores and online. The company said it managed to attract more shoppers who also spent slightly more per visit. Some of its strongest sales were in the baby and toy categories.

"In 2019, we expect to build on this momentum … and deliver profitable growth throughout the year," Cornell said in a statement.

Target said digital sales were up 29 percent during the holidays, thanks to the retailer offering more delivery options like buy online pick up in store. It said the amount of online orders fulfilled through either in-store pickup or a curbside pickup services was up 60 percent from a year ago and accounted for roughly 25 percent of online sales during November and December. Target said it remains on track to report digital sales growth of more than 25 percent in 2018, which would make it the fifth consecutive year it's been able to do so.

Target is still expecting same-store sales growth of roughly 5 percent during the fourth quarter, and adjusted earnings per share for fiscal 2018 of $5.30 to $5.50. Analysts who cover the company have been calling for fourth-quarter same-store sales growth of 5.1 percent and full-year earnings of $5.39 per share, according to a survey by Refinitiv.

Should Target meet its same-store sales expectations for the fourth quarter, the company said, it will make 2018 its strongest year for sales growth since 2005.

Just before the holiday season, Cornell told analysts there was "no sign" consumer spending was cooling. That was after he said the consumer environment in the U.S. was in best shape he'd seen in his career, helping fuel Target's growth.

Target's latest investments — like remodeling bigger stores, opening up smaller-format shops in certain cities and adding more in-house brands — "are helping it compete with the likes of Walmart in terms of prices, the department stores in terms of merchandising, and Amazon in terms of delivery," Telsey Advisory Group analyst Joseph Feldman said in a note to clients ahead of Thursday's press release.

Feldman was expecting Target's same-store sales would be up 5 percent during the holidays. Like many retailers, he said Target should have benefited from a longer shopping season — more days in between Thanksgiving and Christmas — and the demise of Toys R Us and the bankruptcy filing by Sears.

In addition to Smith's departure as Target CFO, which is expected to happen once a successor is named, Target said its HR chief, Stephanie Lundquist, will take a new role as president of food and beverage. She will be reporting directly to Cornell. Melissa Kremer will be taking over Lundquist's HR role.

As of market close on Thursday, Target shares are up about 3 percent this year, bringing the retailer's market cap to roughly $35.6 billion.