By Allison Prang

Mastercard Inc.'s revenue in the second quarter tumbled nearly 20% as the Covid-19 pandemic continued to weigh on business.

Mastercard's revenue was $3.34 billion, down 19% from a year earlier. The company's top line beat the consensus estimate from Wall Street of $3.25 billion, according to FactSet.

The revenue drop was in part from a slump in gross-dollar volume, or the value of card transactions, which fell 10% on a local currency basis. Also leading to the revenue decline was a drop in cross-border volume, which fell 45% on a local currency basis, and switched transactions, which fell 10%. Switched-transaction revenue comes from the company authorizing, settling or clearing transactions.

The company reported earnings for the quarter that ended in June of $1.42 billion, or $1.41 a share. Those earnings declined from a year earlier $2.05 billion, or $2 a share.

Adjusted earnings were $1.36 a share.

According to FactSet, Wall Street expected $1.16 a share.

The company recorded a $22 million litigation provision for the quarter. Those charges were related to fees and litigation settlements with merchants in the U.K. and pan-Europe, Mastercard said.

Visa Inc., which reported results earlier this week, also logged results that were heavily affected by the Covid-19 pandemic. The company saw a 10% drop in payments volume.

Write to Allison Prang at allison.prang@wsj.com