No one likes to lose money on their investments. This is especially true if you have converted a Traditional IRA into a Roth IRA and paid your taxes on that higher value, only to see your portfolio balance decline after it was moved to the Roth.

The problem is, after the conversion you won’t be able to claim any of these tax losses. If the value had dropped before the conversion, you’d have paid taxes on a lower valuation. But if the drop happens after the funds are in a Roth, it’s too late.

Almost. There is one important “out”: You may be able to recoup some of your lost money if you undo your Roth IRA conversion (the technical term is “recharacterizing” it) and then harvest your tax losses.

Before we describe how that would work, you need some explanations.

What Does It Mean to Harvest Tax Losses?

With traditional taxable investments, there are actually two approaches to harvesting your tax losses: (1) offsetting capital gains with losses, and (2) deducting your losses.

With the first approach, you can offset your losses on your current year’s tax return with any capital gains that you earn. This can dramatically lower the amount of tax you pay on your capital gains. For example, if you own shares in a company’s common stock that have tanked along with a bad stock market—giving you a paper loss of $3,000—you can sell those securities and use that loss to offset any profits that other investments had  earned during that year. That loss could essentially wipe out any $3,000 taxable gain from other investments in the Internal Revenue Service’s (IRS) eyes.

Remember, though, that you actually have to sell the investments in question and realize both the loss and the capital gains to harvest tax losses this way.

There’s also another route: If you don’t sell any investments that have experienced capital gains, you can still harvest your losses for tax purposes. In this case, you simply deduct the $3,000 loss on your taxes.

Does Harvesting Tax Loss Apply to Roth IRAs?

The short answer is no. Because a Roth IRA allows investors to withdraw their investments, profits, interest, dividends and capital gains tax-free in retirement, losses occurring in a Roth IRA do not quality for tax harvesting. Within a Roth, any tax losses or gains are irrelevant.

But the conversion gives you a special opportunity. Because you just did it, you may still be able to take tax advantage of losses in the value of your investments by undoing that Roth IRA conversion. When you originally converted your Traditional IRA to a Roth, you paid taxes on the value of your account at that time. Since your new Roth IRA investment sank to a much lower account balance, reverting back to a Traditional IRA would provide you with a refund of the taxes that you originally paid when it was worth more. This is called a recharacterization of your contribution.

Be aware that there are stringent tax rules for how quickly you have to do that recharacterization: You have six months after the due date of that year’s taxes (generally October 15 after April 15) to accomplish this goal. Get tax advice and be sure to follow every step correctly.

Of course, now that it’s back in a Traditional IRA, eventually you will owe taxes on the amount of money you withdraw from it.  But in the meantime, you won’t have paid too much in taxes for making the conversion of an account that then plummeted in value.

Should you decide later to re-convert your new, less valuable Traditional IRA back into a Roth, you will pay less in taxes than you did the first time. And that is how you will be able to “tax harvest” your investment losses by using them to pay less in taxes than you did when the account was worth more.