Telecom giant AT&T (T -1.37%) spent years, and tens of billions of dollars, attempting to turn itself into a media conglomerate. It acquired DirecTV to bolster its video business, and after nearly two years of legal wrangling, it successfully acquired Time Warner in an $85 billion deal that closed in June 2018.

Time Warner, now known as WarnerMedia, brought with it valuable properties including Warner Bros, HBO, and Turner. But it never quite worked as part of AT&T, and the boatload of debt generated by AT&T's dealmaking made the company far more fragile.

Less than four years after the Time Warner acquisition, AT&T is on the cusp of completing the unwind of its ill-fated and expensive media strategy. DirecTV was spun off as its own company last year, with AT&T maintaining a majority stake. And in the coming days, WarnerMedia will be merged with Discovery (DISCA) (DISCK) to create a media and streaming powerhouse.

Here's what investors need to know.

1. The deal is a tax-free transaction

While some other options were batted around, the merger of WarnerMedia with Discovery will be structured such that AT&T shareholders will keep their shares of AT&T while receiving shares of the new company, which will be called Warner Bros. Discovery. AT&T shareholders will receive an estimated 24 shares of Warner Bros. Discovery for every 100 shares of AT&T owned.

This spinoff isn't a taxable event, so AT&T shareholders will receive the distribution of Warner Bros. Discovery stock without needing to pay any taxes. AT&Ts shareholders will own 71% of Warner Bros. Discovery, while Discovery shareholders will own the remaining 29%.

2. AT&T will get to pay down some debt

AT&T's spending binge did a number on its balance sheet. The company had nearly $180 billion in debt at the end of 2021, including just over $150 billion in long-term debt.

The picture will get a little better once the spinoff is complete. AT&T will receive $43 billion as part of the deal in the form of cash, debt securities, and Warner Bros. Discovery's retention of debt. The goal is to use this windfall along with free cash flow to reduce the net debt to adjusted EBITDA ratio to around 2.5 by the end of 2023.

An improved balance sheet will an asset as AT&T spends heavily to build out its 5G network. The company will pour $5 billion into deploying 5G spectrum this year alone as part of its $24 billion capital spending plan.

3. AT&T will remain a cash flow machine

The spinoff of WarnerMedia will make a dent in AT&T's free cash flow, but the core wireless business will remain a cash machine.

A chart showing AT&T's free cash flow over time.

Chart by author. Data source: AT&T.

Using AT&T's new definition of free cash flow, the company expects the pro forma metric to dip to $16 billion this year, then recover to $20 billion in 2023. That leaves plenty of cash to pay dividends and to make some serious progress chipping away at the debt load.

4. The dividend is getting cut

AT&T is using this opportunity to bring its dividend payments back down to a sustainable level. The company will now pay a quarterly dividend of $0.2275 per share, or $1.11 annually. That's nearly a 50% cut from its previous $2.08 annualized per-share dividend.

In exchange for the dividend cut, investors not only receive shares of Warner Bros. Discovery, but their stake in AT&T becomes less risky. AT&T's balance sheet will be stronger, and it will have the resources to invest in 5G and other growth initiatives. Had AT&T kept its larger dividend payment, the company would have been at a disadvantage.

5. The stock could slump right after the spinoff

AT&T warned investors that they should expect the price of AT&T stock to adjust to reflect the transfer of WarnerMedia to Warner Bros. Discovery. Exactly what happens to the stock price once the spinoff is complete is anyone's guess, but any dip could be a buying opportunity.

Right now, AT&T is valued around $170 billion. If you take the company's 2023 free cash flow guidance at face value, the market is valuing AT&T including WarnerMedia at less than 9 times pro forma free cash flow. If the stock drops following the spinoff, investors may be able to snag shares of the leaner AT&T that emerges at an even lower multiple.

This assumes, of course, that AT&T's guidance isn't overly optimistic. But the rock-bottom valuation gives investors a sizable margin of safety in case things go wrong for the telecom giant.