CVS Caremark (CVS) reported a 12% improvement in its fourth-quarter earnings, beating Wall Street estimates amid stronger drugstore sales and growth at the company’s pharmacy benefit management business.

The nation’s second-largest pharmacy chain also raised its guidance for the first quarter to a profit of $1.03 to $1.06 a share, up from a prior outlook of 96 cents to 99 cents. CVS affirmed its full-year view.

Shares rallied 3.8% to $69.50 in pre-market trading on Tuesday.

CVS said its profit climbed to $1.27 billion, or $1.05 a share, from $1.13 billion, or 90 cents a  share, in the year-ago period. Excluding one-time items, adjusted per-share earnings checked in at $1.12, up from 96 cents. Revenue jumped 4.6% to $32.83 billion.

Analysts were anticipating adjusted earnings of $1.11 a share and revenue of $32.67 billion.

Revenue in its PBM unit was up 5.2% at $19.6 billion. CVS processed 204.9 million pharmacy network claims, down 0.3% year-over-year.

Retail sales grew 5.6% to $17.2 billion, as same-store sales rose 4%. Comparable store sales for CVS pharmacies increased 6.8% on higher prescription volume. In the front of CVS stores, same-store sales declined 1.9% amid weaker traffic.

“As expected, the quarter was somewhat atypical, largely due to the timing of Medicare Part D profits within the PBM and the timing of break-open generics across the enterprise,” Chief executive Larry Merlo said.

CVS made headlines last week when it announced plans to stop selling cigarettes and other tobacco products in its 7,600 drugstores by October. CVS said selling cigarettes is inconsistent with its purpose as a healthcare company. The move will slash annual revenues by $2 billion.

Follow Matthew Rocco on Twitter @MatthewRocco