It was the worst first half for the S&P 500 in 50 years -- and Berkshire Hathaway was buying stocks aggressively. In the first quarter of 2022, CEO Warren Buffett and his investing team poured $51 billion into equities, and they added another $6 billion in the second quarter. 

One company that Buffett and Berkshire bought in both quarters was Markel (MKL 0.56%), which offers specialty insurance coverage. After Berkshire added 420,000 shares totaling $620 million in the first quarter, the company added another 47,000 shares worth $59 million at recent prices. Should Markel be on your list too? Here's what you should know.

An image of Warren Buffett, Berkshire Hathaway CEO.

Image source: The Motley Fool.

Markel has excelled at writing policies on hard-to-place risks

Markel writes insurance on hard-to-place risks, known as excess and surplus (E&S) insurance. These are risks that traditional insurance companies don't always cover -- or, in some cases, don't cover at all -- including wind and earthquake, classic cars, and transaction-related risks.

Competition in the specialty insurance market is less about competing on prices and more about using built-up expertise to manage unique types of risks. Markel has done a solid job of managing its risks, which you can see from its combined ratio.

The combined ratio is a useful measure of how much a company makes (or loses) from its policies, and is calculated from the sum of claims and expenses divided by total premiums collected. A ratio under 100% means a company is writing profitable policies -- the lower the ratio, the better. Over the last decade, Markel's combined ratio has averaged 95.5%. 

Warren Buffett loves insurers for this reason

Warren Buffett has been a longtime fan of insurance companies, and for a good reason. Insurers are cash-generating machines in part because they collect fees before providing their service. As a result, insurers have a pile of cash called float, which they can use until policyholder claims deplete it.

When insurers write profitable policies over a long period, they can generate impressive free cash flows -- money they can use to pay dividends, pay down debt, or invest. Over the past decade, Markel's free cash flow has grown nearly 25% on a compound annual basis.

MKL Free Cash Flow Chart

MKL Free Cash Flow data by YCharts

Markel has aggressively poured money into its investment portfolio, which has earned it the nickname "baby Berkshire." Markel's stock investment portfolio totals $7 billion, and its top holdings include Berkshire Hathaway itself, Brookfield Asset Management, Alphabet, and Home Depot

It also has its Markel Ventures segment, where it owns an interest in businesses outside of insurance, including building products, crane rental services, and luxury consumer goods. This segment has seen operating revenue grow at a compound annual rate of 25% since 2017. 

Markel could be a solid investment if inflation persists

Despite solid underwriting and impressive free cash flows, Markel has underperformed the market over the past decade, returning 190% compared with the S&P 500's total return of 266% in the same time.

However, Buffett's investments suggest that the Oracle of Omaha thinks inflation could stick around longer than expected. For example, Buffett now has a $12 billion stake in Occidental Petroleum and owns 20% of the oil giant. Insurers can be solid hedges against inflationary pressures because of their pricing power, allowing them to adapt to rising costs. Markel's earned premiums have grown 17% through the first six months of this year. 

Markel is in a solid position to weather a potential recession on the horizon and can adapt to inflationary pressures if they persist, which are likely the reasons Buffett added more to his position in the second quarter.