The Roth IRA is a wonderful retirement savings tool, and one that far too few Americans take advantage of. And while there are some income limits that prevent the highest earners from utilizing it, the vast majority of American workers qualify to make contributions of as much as $5,500 to a Roth IRA each year.

That money will then grow completely tax free, and -- this is when it gets even better -- when you take distributions in retirement, it's still tax-free.

Don't give up the biggest thing that makes the Roth IRA worthwhile: Tax avoidance. Image source: Getty Images. 

As long as you don't touch the money until you've reached retirement age, you'll never, ever pay taxes on it, no matter how big your gains are from the investments.

That is, unless you make the mistake of investing in the wrong category of stocks in your Roth: Master Limited Partnerships. Bottom line: This is a group of stocks I'd never put in a Roth IRA, because it potentially wastes the one reason why Roths are such a wonderful way to invest for retirement -- no taxes.

What is a master limited partnership?

A master limited partnership, or MLP, is a kind of business structure for publicly traded limited partnerships. In short, it's not a corporation, which the vast majority of publicly traded companies are, and doesn't pay corporate income tax, instead passing along the obligation to its investors. 

MLPs, which typically hold energy and infrastructure assets, are popular investments because they generally pay generous dividends from stable cash flows. This can make them seem enticing to own in a tax-advantaged traditional or Roth IRA. What's better than a steady stream of tax-free income, after all? And these kinds of investments can be market-crushing, due to both steady growth, and the income they pay.

Here's a look at how three top MLPs, Magellan Midstream Partners, L.P. (NYSE:MMP), ONEOK Partners LP (NYSE:OKS), and Brookfield Infrastructure Partners LP (NYSE:BIP), have performed for investors over the past decade:

MMP Total Return Price Chart

MMP Total Return Price data by YCharts

Those are wonderful, market-beating returns. One minor problem: Since these are MLPs, those returns may not be tax-free in your Roth (or other) IRA.

When the investing gains aren't tax-free after all

The first problem with owning MLPs in a Roth IRA is UBTI, or Unrelated Business Taxable Income.

Without getting into the weeds too much, MLPs (and LLCs, a corporate structure with similar benefits as MLPs) don't pay income tax directly. Instead, MLP's pass that obligation along to investors, broken down on the Schedule K-1 investors receive from the partnership each year, that must be used when investors file their taxes. And if you own those units inside a Roth or traditional IRA, there is no guarantee that you won't still have to pay tax on your share of the income.

Don't get caught off guard by the taxman with your retirement savings. Image source: Getty Images. 

Specifically, if your total UBTI on all MLP investments in your Roth exceeds $1,000, you'll have to pay UBTI. There's some "good news, bad news" in that. Very few Roth investors will be generating $1,000 or more in UBTI, without a pretty large MLP investment.

But for long-term investors, the risk is that over time, by owning to heavy a mix of MLPs, you'll eventually break that threshold, and not even realize it before you end up owing UBTI inside what should be a tax-free account.

Alternatives to MLPs

In some cases, there are indeed ways to benefit from the assets held in an MLP without having to own the MLP directly. The most ideal is in the case of ONEOK Inc (NYSE:OKE), a regular corporation that is essentially a pure-play on ONEOK Partners. ONEOK is the general partner of ONEOK Partners, meaning it runs the MLP, and also holds a substantial equity interest in it. To a lesser degree, Brookfield Asset Management Inc (NYSE:BAM) is one way to get exposure to Brookfield Infrastructure Partners. However, Brookfield's business interests are far broader than just running its infrastructure MLP, including three other master limited partnerships, private funds it invests in and public securities it owns.

And while ONEOK has been a better investment than the MLP it manages, Brookfield Asset Management hasn't been anywhere near as good an investment as Brookfield Infrastructure since that partnership was taken public:

OKS Total Return Price Chart

OKS Total Return Price data by YCharts

Buyer beware

Roth IRAs are wonderful, but only if you utilize the tax-free nature of their structure. And unfortunately, this means MLPs are simply a class of stocks that are best avoided for your Roth or even traditional IRA. No matter how wonderful an investment that MLP may seem, the potential of having to pay taxes on them when there are almost certainly equally wonderful investments that would be tax-free, just makes them downright unsuitable for retirement accounts. If you want to own them -- and I do own Brookfield Infrastructure -- make sure it's in your taxable brokerage account.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.