By Dave Sebastian

CVS Health Corp. raised its expectations for the full year as its insurance business booked lower health-care benefit costs due to the deferral of elective procedures amid the coronavirus pandemic, though shelter-in-place measures also led to fewer new prescriptions.

The pharmacy chain, which also owns the insurance giant Aetna, on Wednesday said it now expects earnings of $5.59 to $5.72 a share, or $7.14 to $7.27 a share on an adjusted basis. It previously expected earnings of $5.47 to $5.60 a share, or $7.04 to $7.17 a share on an adjusted basis.

The company said it sees more people using their insurance for health care in the second half of the year. States have emerged from lockdown measures implemented in March, though some are seeing a resurgence in Covid-19 cases.

CVS posted second-quarter profit of $2.98 billion, or $2.26 a share, compared with $1.94 billion, or $1.49 a share, in the same period last year. Adjusted earnings were $2.64 a share, ahead of the $1.91 a share analysts polled by FactSet had expected.

The Woonsocket, R.I.-based company reported sales of $65.34 billion, up 3% from the year-ago period, beating Wall Street estimates.

Sales in the company's health-care benefits segment, which includes Aetna, rose 6.1% to $18.47 billion. It reported a medical-loss ratio, or the share of premiums the insurer pays out in claims, of 70.3%.

Sales in the company's segment that fulfills medication prescriptions and sells general products rose 1% to $21.66 billion, though prescriptions filled declined 1.1% on a 30-day equivalent basis and front-store revenues fell 4.6%. Pharmacy-services segment sales rose slightly to $34.89 billion, partially offset by lower provider visits during the quarter.

CVS, the biggest retail-chain conductor of Covid-19 tests in the U.S., said it has opened more than 1,800 test sites at drive-through locations. But test results have taken longer than customers have been told, and some CVS employees involved in testing have expressed concerns about the delays and said the company hasn't been transparent about wait times for the results, The Wall Street Journal reported last month.

Shares rose about 3% in premarket trading.

Write to Dave Sebastian at dave.sebastian@wsj.com