Shares of the drugstore chain and pharmacy benefit manager (PBM) were up 2.7 percent at $75.70 in morning trading.

The company said it believes the Aetna deal will help it save more than $750 million in costs in the second year after it closes, as the combination reduces corporate expenses as well as produces "some" cuts in medical costs from decreased emergency room visits.

"The longer term medical cost savings will come from new programs that are only made possible through the combination and close integration of our two companies," Chief Executive Officer Larry Menlo said on call with analysts.

CVS, which last month won U.S. Department of Justice approval to buy Aetna, said it reached agreement with the state of California on the acquisition and expects to finalize terms over the coming days. The deal is expected to close before the Thanksgiving holiday, which falls on Nov. 22, CVS said.

The combination is expected to reshape the healthcare sector as it brings together one of the largest PBMs and one of the nation's oldest health insurers.

CVS could offer more preventive care services and screenings to Aetna customers in its clinics, such as enabling diabetes patients to monitor blood sugar levels, avoiding higher cost visits to doctors or emergency rooms.

Pharmacy same-store sales rose 8.7 percent in the quarter, while analysts were expecting a 7.7 percent rise.

Front end of the store same-store sales rose 0.8 percent versus analysts' expectations of an 0.8 percent drop, despite brick-and-mortar drugstore chains like CVS coming under increasing pressure from consumer shifts to online options.

Sales of beauty products at CVS stores have benefited from promotions and newer offerings. Last year, the company announced a initiative to offer over a hundred new South Korean beauty brands at its stores.

Excluding items, CVS Health said it earned $1.73 per share, topping analysts' average estimates by 2 cents.

Net revenue rose 2.4 percent to $47.27 billion, beating expectation of $47.18 billion.

Net income rose to $1.39 billion, or $1.36 per share, in the quarter. Its income tax provision declined by $268 million. (https://bit.ly/2D48hy8)

(Reporting by Manas Mishra and Manogna Maddipatla in Bengaluru; Editing by Arun Koyyur and Bill Berkrot)

By Manas Mishra