A certificate of deposit (CD) may earn a yield higher than a traditional savings account, so it can be a good choice if you’re willing to lock in the funds for a set term. CD terms typically range from three months to five years, and their guaranteed annual percentage yield (APY) can make them worthwhile in a falling-rate environment.

The right CD term for you depends on when you’ll need access to the money. Generally, the longer the term of the CD, the higher APY is likely to be. Federal Deposit Insurance Corp. (FDIC) banks and National Credit Union Administration (NCUA) credit unions often offer both CDs and at least one savings account.

Since withdrawing the funds early can result in a penalty, CDs are best for those who already have an easily accessible emergency fund in a savings account.

Short-term CDs

Short-term CDs typically have terms of up to one year. Putting money into short-term CDs can help maximize the interest you’ll earn on funds earmarked for purchases in the near future, such as an upcoming vacation, home renovations or next year’s holiday gifts.

A short-term CD can be a component of a CD ladder in which multiple CDs are purchased with staggered maturity dates. This savings strategy, which involves short-term, midrange and long-term CDs, helps ensure access to funds at regular intervals with the benefit of the higher rates of the long-term CDs.

Pros of a short-term CD

An upside of a short-term CD is you’ll have access to your money relatively soon, so it may be less likely you’ll need to withdraw the funds before the CD matures and be subjected to an early withdrawal penalty.

Cons of a short term CD

A potential disadvantage of short-term CDs is they may earn a lower rate than longer-term CDs. For instance, the highest rate on a five-year CD is currently more than double that of a six-month CD.

What’s more, while you might need the funds from your short-term CD relatively soon, they’re not as accessible as money in a liquid savings account, since you can lose much of the interest for withdrawing money before the CD matures. For instance, early withdrawals from a one-year CD may incur a penalty of between two and six months of interest.

Midrange CDs

Midrange CDs can include those with terms greater than a year and up to three years in length. People may open a midrange CD to save for a new car or for planned life events such as getting married or having a baby.

Pros of midrange CDs

In exchange for locking in your money for a bit longer than is required for a short-term CD, midterm CDs may help you earn a somewhat higher rate. For instance, you currently can earn significantly higher APYs with some two-year CDs and one-year CDs than with CDs of shorter terms.

Cons of midrange CDs

While midrange CDs tend to earn a higher yield than their shorter-term counterparts, not having access to some of your funds for a couple of years is something not everyone can afford — especially for those who don’t have an easily accessible emergency fund.

Long-term CDs

Long-term CDs generally range between three and five years. These accounts can help you earn significant interest on funds earmarked for use in several years, such as the down payment on a house or putting an addition on your home.

Pros of long-term CDs

Agreeing to lock up your money for several years can help you earn a much higher yield than you’d receive from many CDs with shorter terms. For instance, if you put $5,000 into a CD for five years at a currently available rate of 3.5 percent, you’d have around $5,938 when the CD matures — since it will have earned around $938 in interest. Putting the same amount of $5,000 into a one-year CD that pays 2.5 percent, however, will give you $5,125.00 when the year is up, which includes around $125 in interest.

A CD calculator can come in handy in figuring out what your final balance will be when a CD matures.

A long-term CD can be a good investment if you believe interest rates on deposit products will start to fall and remain low. Locking in a high rate now will guarantee you’ll get that yield, even if rates do plunge.

Cons of long-term CDs

With a long-term CD, the money won’t be freed up for several years, so you could be losing out on a better yield if rates increase in the meantime. What’s more, CDs might not keep up with inflation, in which case your money loses purchasing power.

Another potential downside to long-term CDs is it might be difficult to leave the money untouched for several years if your financial situation takes a turn for the worse due to factors like a sharp rise in inflation or an unexpected job loss.

No-penalty CDs

Consider a no-penalty CD if you prefer a fixed rate but are concerned about the possibility of needing the funds before the term expires. These CDs allow you to withdraw the money prior to the CD’s maturity date without paying a penalty for doing so. (Making a withdrawal isn’t typically permitted within the first week of opening a no-penalty CD, however.)

No-penalty CDs often come with terms between six and 14 months. In exchange for giving you the ability to access the money, they often pay a lower rate than CDs that have such penalties. When considering no-penalty CDs, it can pay to compare their rates to those of savings accounts and money market accounts in the event a higher yield can be found elsewhere.

Finding a CD with the best rate

Regardless of what term of CD you’re seeking, it can pay to shop around for the CD with the highest rate. Online-only banks — which don’t have the cost of maintaining branches — typically offer the best rates.

You may also find comparatively high CD rates at credit unions, since their profits go back to members — which can translate to higher APYs on deposit products as well as lower rates on loans.

Alternatives to CDs

The fact that CDs lock in your money for a set term can sometimes make other types of accounts a better choice. For instance, money that needs to be readily available for unexpected expenses such as car repairs or medical bills is better off in a liquid, high-yield savings account than a CD, since you won’t be subjected to early withdrawal penalties.

While you may have other funds that you don’t plan to access in the near future — such as those you’re setting aside for retirement — this money might be better off invested in places other than CDs. You may earn a significantly higher yield from investments such as S&P 500 index funds, 401(k) accounts or traditional IRAs. A thorough understanding of your investment options — which may involve hiring a financial advisor — can help you make informed decisions.

Bottom line

While a CD’s term length can affect its rate of return, you’ll ultimately want to choose a short-term, midrange or long-term CD based on when you’ll need access to the money. Shopping around for the right term and the best yield can help you meet your financial goals.