CarMax (KMX) reported on Tuesday stronger-than-expected earnings for the second quarter, as the company’s profit leaped 26% amid stronger sales of used cars.

Shares climbed 4.1% to $52.08 in pre-market trading. The stock is already up 33.2% so far this year.

CarMax, the nation’s largest used-vehicle seller, said its profit rose to $140.3 million from $111.6 million in the year-ago period. On a per-share basis, earnings checked in at 62 cents versus 48 cents, beating Wall Street expectations for 57 cents.

Revenue was up 18% at $3.25 billion, surpassing a $3.16 billion estimate. Gross margin widened to 13.4% from 13.3%.

The company’s auto-finance unit saw its income climb 12% to $84.4 million.

CarMax has seen growing demand for used cars as a result of the slow economic recovery. In the latest period, CarMax logged a 21% increase in the number of used vehicles sold, or 16% on a same-store basis. Total sales for used vehicles rose 20% to $2.64 billion.

The volume of wholesale sales grew 10%, thanks in part to additional stores and an increase in the appraisal buy rate.

Follow Matthew Rocco on Twitter @MatthewRocco