Unlike a 401(k), you can take your money out of a traditional IRA any time you feel like it. The catch is that if you're under 59 1/2, you not only pay income tax, but you also pay a 10 percent tax penalty on the withdrawal. The IRS may cut you some slack on the penalty, however, if you have big medical expenses that year.
There's no penalty if your withdrawals are no more than your family's medical expense write-off for the year. To figure how much you can claim, add up the expenses and subtract -- as of 2013 -- 10 percent of your income. What's left is your write-off. If your withdrawal was smaller, there's no penalty, even if you don't take a medical deduction. If you're unemployed, you can take penalty-free withdrawals to pay for your medical insurance. The IRS also lets you make no-penalty withdrawals if you're disabled.
When figuring your medical-expense write off, you only count deductible expenses listed in IRS Publication 502. It doesn't matter whether you claim the deduction; the expenses have to be listed, though, for you to avoid the IRA penalty. They include the obvious -- hospital stays, doctor's appointments -- and less obvious ones such as breast pumps, acupuncture, and travel costs for visiting doctors. If you include expenses such as getting a hair transplant or buying OTC drugs, the IRS will tell you "no."
If you take an early withdrawal, you report it using Form 5329. In the first section of the form you list your total withdrawals, then the penalty-free amount. If you have any withdrawals that you do owe the 10 percent on, you calculate the penalty tax on Form 5329, and then report it on your 1040. The Form 5329 instructions include a list of code numbers identifying the different exemptions from the penalty; enter yours as appropriate. Even if you're completely penalty-free, you still enter the withdrawal as regular taxable income on your 1040 and pay regular income tax on it.
The rules for Roth IRAs are different. You can withdraw contributions at any time, because you paid tax on them when you put the money in the account. Earnings are taxable if you withdraw them early, but the IRS lets you make all withdrawals from contributions until you exhaust them. You get a Form 8606 from your account manager showing your total withdrawals for the year, and how much, if any, is taxable income. Apply the hardship withdrawal rules to see if you owe penalties on that part.