The big transition taking shape in the energy space is the shift from carbon fuels, like oil, to cleaner alternatives, like electricity. But this switch is likely to be a multidecade affair, leaving plenty of time for investors to collect distributions from well-positioned industry players like Magellan Midstream Partners (MMP) and Sunoco LP (SUN 1.32%). Here's what you need to know.

Still down, not out

Magellan's master limited partnership (MLP) units are up 40% since their mid-March 2020 lows. Sunoco's units have advanced an even more impressive 129% over that same span. And yet both are still around 40% below their high water marks in 2015 or so. In other words, they still have not fully recovered.

That's highlighted by their distribution yields. Magellan's yield is 8.7% while Sunoco's is an even larger 9.2%. Both are high on an absolute basis, noting that the S&P 500, despite the current bear market, yields a tiny 1.4%. And while Sunoco's distribution hasn't been increased since 2016, neither has it been cut. Magellan, meanwhile, has increased its distribution every year since its initial public offering in 2001. So the high yields here also likely indicate a relatively attractive entry point.

On that score, it's important to note that Sunoco covered its distribution by a hefty 1.6 times in the first quarter. There's plenty of room for adversity there before a cut would likely be in the cards. Magellan's coverage is a bit tighter, with a coverage target of roughly 1.2 times, but it has among the strongest balance sheets in the midstream space. Again, it doesn't look like there's a big risk of a distribution cut here, either. 

What's the problem?

The issue facing both of these MLPs is at least partly related to what they do. Magellan generates around 28% of its operating margin from oil pipelines with the rest coming from refined product pipelines (largely gasoline and diesel fuels). While Sunoco has been diversifying its business into the midstream space, it still ends up being the country's largest fuel distributor. These are decidedly carbon-heavy businesses that are being disrupted by the shift toward electric vehicles.

This may not be as big a threat as it seems. Sunoco estimates that in a high electric vehicle sales scenario, EVs will still only be around 45% of the nation's vehicle fleet by 2040. In a low EV sales scenario, that figure could languish in the single digits for years. While there's no way to know what is going to happen, the end result in even the best-case EV scenario is that there is still going to be a need for gasoline for a long time to come. With entrenched positions, Magellan and Sunoco will be there to benefit and pass income on to unitholders.

Worth the risk?

Clearly, neither Magellan nor Sunoco is a risk-free investment. However, investors appear to be pricing them as if their businesses are on the verge of extinction. That doesn't seem to be true, and they still have ample support for their distributions. If you can handle taking a contrarian stance, you might want to take a closer look at these bargain-priced energy names.