Tech stocks have soared since the start of the pandemic. The tech-heavy Nasdaq Composite has more than doubled since bottoming out last March, and some tech stocks have left the index in the dust. If you've owned semiconductor stocks like NVIDIA or software stocks like Cloudflare, you've done very well over the past year and a half.

If you've owned shares of telecom giant AT&T (T -1.37%), you have not done very well. AT&T is down about 10% from its March 2020 low, and it's down 20% over the past three years. At its core, AT&T is a leading wireless network that throws off an incredible amount of cash each year. But the company's plan to turn itself into a media conglomerate, kicked off by its acquisition of DirecTV, has been a comedy of errors.

Buy now spelled out in red on keyboard keys.

Image source: Getty Images.

Unwinding a failed strategy

AT&T paid $49 billion for DirecTV in 2015. It then shelled out $85 billion for Time Warner in 2018. The value of combining a satellite TV provider and a media company with a telecom giant was never very clear. AT&T's balance sheet ended up loaded to the gills with debt, and interest payments ate away at the cash flow generated by the wireless business.

AT&T tried to make it work for years, but the company is now thankfully unwinding its mistakes. DirecTV and AT&T's U.S. video business were spun off into a new company earlier this year, with AT&T receiving $7.1 billion in cash and a 70% stake. The transaction valued DirecTV at $16.25 billion, a far cry from the price AT&T originally paid.

As for Time Warner, now known as WarnerMedia, AT&T is set to combine the entertainment subsidiary with Discovery in a move that will create a company with $52 billion of annual revenue. AT&T will receive $43 billion in the form of cash, debt securities, and WarnerMedia's retention of debt, and AT&T shareholders will own 71% of the new company.

Once the WarnerMedia deal closes next year, the new AT&T will be able to focus on its core telecom business.

Two cash machines

When a large, slow growing company owns valuable assets that have significant growth potential, the market often doesn't give that company credit. The sum of the parts is worth more than the whole, in other words. If investors are going to value AT&T like a telecom company regardless of what media assets it owns, the best thing to do for shareholders is to split up the company.

AT&T will be a telecom company again after the deal goes through, and a highly profitable one at that. The company is expecting to produce around $20 billion in annual free cash flow in 2023. AT&T is currently valued at $180 billion, just nine times that projected free cash flow.

AT&T shareholders will also own the bulk of the new media company. Based on what AT&T said when the deal was first announced, the WarnerMedia-Discovery mashup is expected to produce $52 billion of revenue and $14 billion of adjusted earnings before interest, taxes, depreciation, and amortization (EBITDA) in 2023, with roughly $8.4 billion of that EBTIDA converted to free cash flow.

For $180 billion, you get a slow-growing telecom company that will produce $20 billion of free cash flow annually, a media company with valuable assets like HBO Max, and solid growth prospects that will produce $8.4 billion of free cash flow annually. That seems like a pretty good deal to me.

Of course, there's plenty that could go wrong. These estimates coming from AT&T could prove wildly optimistic. The wireless business could get more competitive, or 5G may not drive the kind of growth the company is expecting. For the media company, an increasingly crowded streaming market with Netflix and Disney leading the way may prove a tough nut to crack.

But even if AT&T is painting an overly rosy picture, it's hard to see how buying AT&T stock today can go all that wrong in the long run. This looks like a low-risk proposition to me. And if the media company does well and turns HBO Max into a streaming leader, it could be worth a lot more down the road. There's not a ton of downside, but there's plenty of potential upside.

The market is extremely pessimistic on AT&T stock right now. It's time to take advantage.