Tax-deferred accounts such as IRAs are a great way to save for retirement. But if you like to invest in dividend stocks, there's a tax trap that you need to understand in deciding how to invest your IRA assets.

In the following video, Dan Caplinger, The Motley Fool's director of investment planning, looks at an often-overlooked aspect of IRA taxation. Dan notes that IRAs offer the valuable benefit of tax deferral, meaning you don't have to pay taxes on dividends so long as you don't make withdrawals from your IRA. But Dan warns that when you take money out of the IRA, it all gets taxed at your ordinary income tax rate -- even if lower dividend tax rates would ordinarily have applied in a regular taxable account. Dan says there's no reason to worry about having in an IRA Annaly Capital Management (NLY 0.66%), American Capital Agency (AGNC 0.21%), and other dividend-paying investments that typically don't qualify for lower tax rates on their payouts. But for Altria Group (MO 0.43%), AT&T (T -0.06%), and other popular stocks that do generally qualify for lower dividend tax rates, you should determine whether the benefits of tax deferral outweigh the added tax you might pay in retirement.

Jar of coins labeled dividends

Image source: Getty Images.