Say you have $10,000 and two places to put it: a 12-month certificate of deposit at 4%, or a high-yield savings account at the same bank paying 3.5%. A certificate of deposit, or CD, is a deposit you agree to leave alone for a set term, and the bank pays a higher rate in exchange. If you take the money out before the term ends, the bank charges an early withdrawal penalty. These rates are examples. Yours will be different, and both kinds of rates move up and down over time.

If you hold it the full year

The CD pays about $400 in interest over 12 months. The savings account pays about $350. So the CD comes out $50 ahead, as long as you don't touch the money.

If you need it at six months

A common penalty on a 12-month CD is 90 days of interest. On $10,000 at 4%, 90 days of interest is about $99.

At six months the CD has earned about $200. Take out the $99 penalty and you keep about $101. The savings account would have paid about $175 by then, and you could have taken the money out any day without paying anything. That means breaking the CD early left you about $74 behind the account with the lower rate.

In this example the CD never catches up if you break it inside the year. The extra half a percent adds about $4 a month, and it would take almost two years of that to cover a $99 penalty.

Read the penalty before you open one

Banks set their own penalties. Some charge 90 days of interest on a short CD, some charge six months or a full year, and longer CDs usually carry bigger penalties. Some banks also offer a no-penalty CD at a lower rate. The penalty is spelled out in the account disclosure, and it matters as much as the rate in the ad.

Which money belongs in a CD

A CD fits money with a date on it that falls after the term ends, like a tax bill due in 14 months or a car you plan to buy in a year and a half. It's a poor fit for an emergency fund, because an emergency is the one thing you can't schedule. If there's a real chance you'll need the $10,000 before the year is up, the lower rate you can reach any day will probably leave you with more.

I'm a licensed insurance broker, not a CPA or financial advisor, and interest from either account is taxable in the year it's paid. Before you lock up $10,000, find the early withdrawal penalty in the disclosure and work out what it would cost you if you needed the money at month six.