Trucking company XPO (XPO -6.22%) delivered for investors in the most recent quarter, announcing results that easily beat expectations. The stock responded by zooming into the fast lane, gaining more than 12% on Monday morning.

XPO is back in the driver's seat

XPO is one of the nation's largest providers of less-than-truckload transport, the complex business of filling trucks with packages from multiple customers. The company sputtered last year as it worked through some cost issues, but it appears to now be on the right path.

XPO earned $0.88 per share in the third quarter on revenue of $1.98 billion, surpassing Wall Street's expectations for $0.63 per share in earnings on sales of $1.93 billion. The company's operating ratio, a measure of profitability, improved to 86.2% in the quarter thanks to gains in volumes, pricing, and labor productivity. And XPO's damage claims ratio was a company-best 0.4%, an improvement over 1.2% two years ago.

"Our third quarter results exceeded expectations, with solid growth in revenue and profitability, and strong forward momentum," CEO Mario Harik said in a statement. "We also captured more share in the quarter, as customers responded to our focus on service and investments in capacity."

Is XPO a buy after its blowout quarter?

Shares of XPO are now up 129% year to date, as the company has made steady progress in rebuilding the confidence of Wall Street after a shaky few quarters last year. But even with those gains, XPO still trades at a discount to industry leader Old Dominion Freight Line, a stock that has also beaten the market so far in 2023.

The bull case from here is that XPO can continue to build on its operational improvements and close the valuation gap with Old Dominion. The company has a former long-serving Old Dominion exec helping to lead that charge.

That's no easy task, and truckers need to watch how the economy develops from here and avoid investing heavily in a potential slowdown. But XPO has gone a long way toward making its case that its worst days are behind it, and investors are understandably excited about where the company can go from here.