By Dave Sebastian

Anthem Inc. said its profit and revenue for the second quarter climbed as it saw a deferral in elective health care due to the Covid-19 pandemic.

The health insurer on Wednesday posted net income of $2.28 billion, or $8.91 a share, compared with $1.14 billion, or $4.36 a share, in the year-ago period. Adjusted earnings were $9.20 a share.

Analysts polled by FactSet were expecting earnings of $8.32 a share, or $8.74 a share on an adjusted basis.

The medical-loss ratio, the share of premiums the insurer pays out in claims, was 77.9%. Analysts were expecting 81.2%.

Revenue rose to 16% to $29.26 billion, driven by pharmacy-product revenue related to the launch of IngenioRx, premium revenue due to Medicaid and Medicare growth, and the return of the health insurance tax in 2020. Analysts were looking for $29.39 billion.

The company had 42.5 million members as of June 30, up 3.9% from the year-ago period.

Anthem said it expects full-year net income of more than $20.91 a share. Excluding certain items, it expects earnings of $22.30 a share.

The company said it isn't providing further guidance metrics due to uncertainty caused by the pandemic.

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