Warren Buffett and his company, Berkshire Hathaway (NYSE:BRK-A) (NYSE:BRK-B), have historically avoided investing in tech stocks, simply because Buffett doesn't understand tech very well, and he doesn't like investing in businesses he doesn't understand. However, these days there are a select few tech stocks in Buffett's portfolio -- all of which have Buffett-like qualities.

Company

Recent Share Price

Number of Shares Berkshire Owns

Value of Berkshire's Stake

Apple

$140.64

133,000,000 (est)

$18.7 Billion

IBM

$173.83

81,232,303

$14.1 Billion

Sirius XM

$5.10

166,639,941

$850 Million

Data Source: Berkshire Hathaway SEC Filings as of 12/31/16, except for Apple, which was revealed by Buffett in an interview with CNBC. Share prices as of 3/26/17.

Berkshire's tech stocks and why Buffett likes them

Warren Buffett at Berkshire Hathaway's annual meeting.

Image source: The Motley Fool.

1. Apple

Berkshire first invested in Apple (NASDAQ:AAPL) about a year ago, but the initial purchase represented a relatively small investment for Berkshire. Since then, the stake has roughly increased by a factor of 20, and now represents one of Berkshire's largest stock investments.

The massive increase in Berkshire's Apple investment didn't come as much of a surprise to many investors. In fact, in a December article, I said that Apple was a stock Berkshire should double-down on. Apparently, Buffett and company agreed, and then some.

There are lots of reasons Buffett likes Apple, such as its dominant market position, pricing power, large and steady cash flow, and its 12-figure stockpile of cash. Apple also has "stickiness" -- a favorite term of Buffett's -- as it has one of the most loyal customer bases of any company in the market. Multi-generational iPhone users typically don't just decide to go buy a Samsung phone, for example.

2. IBM

International Business Machines (NYSE:IBM), better known as IBM, was Berkshire's first big venture into the tech sector. Berkshire started building its stake in 2011, and has added to it several times since. In fact, IBM is now one of Berkshire's largest stock investments.

Buffett's purchase of IBM came as a surprise to many investors, however his reasons for buying IBM made sense. As he said in a 2011 CNBC interview, "...we went around to all of our companies to see how their IT departments functioned and why they made the decisions they made. And I just came away with a different view of the position that IBM holds within IT departments and why they hold it and the stickiness..."

As my colleague Tim Green pointed out in an in-depth article about Buffett's IBM investment, most of IBM's revenue comes from clients who use multiple IBM solutions, which creates big switching costs (this is what Buffett means by "stickiness"). And, the company has done a great job of evolving and investing in new areas of technology, such as cloud computing.

3. Sirius XM

Satellite radio provider Sirius XM (NASDAQ:SIRI) is the newest addition to Berkshire's portfolio out of these three tech stocks, with the stake added during the fourth quarter of 2016. And while we don't know for sure why Buffett chose to add Sirius XM, the company does have a lot of qualities that Buffett loves.

For one thing, Sirius XM has a dominant position in an industry whose barriers to entry are high. Think about it -- can you even name the number two satellite radio company (hint: there isn't one). And, the company has begun to demonstrate steady, sustainable growth, and consistent earnings power with revenue rising by about 10% per year for the past three years.

Additionally, the company offers high-demand original content that gives it an edge over other subscription-based streaming services. Howard Stern (who will host his show through at least 2020) is the prime example, but there are a number of popular original programs offered by the service.

Buffett won't buy just any tech stocks

The takeaway here is that Buffett and his stock pickers are less concerned with the industry they're investing in, and more worried about whether or not the company they're buying has the qualities Buffett looks for.

It just so happens that most tech companies have generally produced inconsistent earnings and faced tremendous competitive pressures, which have steered Buffett away. These three companies are exceptions.

Matthew Frankel owns shares of Apple and Berkshire Hathaway (B shares). The Motley Fool owns shares of and recommends Apple and Berkshire Hathaway (B shares). The Motley Fool has the following options: long January 2018 $90 calls on Apple and short January 2018 $95 calls on Apple. The Motley Fool has a disclosure policy.