Freight transportation and logistics company Landstar System Inc posted a higher-than-expected quarterly profit, sending shares up more than 6 percent to their highest level in nearly three years.

The company said strong pricing and an improving freight environment helped boost earnings and revenue, both of which beat analysts' expectations.

Freight haulers have benefited in recent quarters from strong pricing due to tight supply of trucks and drivers.

"Pricing was pretty darn strong," said Matt Young, an analyst at Morningstar. "Maybe a little bit more than I expected, and I'm guessing that's driven by the tight capacity in the industry in general."

Young said trucking companies that shed capacity during the recession have been reluctant to increase supply in recent quarters, creating price increases for haulers. Further crimping supply is a shortage of drivers that one analyst said continues to "haunt the industry."

"I would characterize the overall second quarter freight environment as a little choppy, but moving in an upward direction," Henry Gerkens, the company's chief executive, said in a statement. "Pricing continued to be strong."

Landstar's second-quarter net income rose 22 percent to $29.6 million, or 62 cents a share, from $24.4 million or 49 cents a share a year earlier. Analysts on average were expecting 59 cents a share, according to Thomson Reuters I/B/E/S.

Revenue at the Jacksonville, Florida-based company was $675.6 million. That was above Wall Street estimates of $659.2 million, according to Thomson Reuters I/B/E/S.

The company raised its quarterly dividend 10 percent to 5.5 cents per share.

Landstar said it expects third-quarter revenue and profit to be in line with the second quarter's.

The company provides third-party logistics services by matching shipments with available truck drivers, ships or planes. (Reuters)