My column last week tackled a popular workplace benefit — the Flexible Spending Account, or FSA — and why it's an easy, tax-free way to save for medical expenses. I’ve used my accounts to pay for health insurance copayments and eyeglasses.

But an FSA isn’t the only choice when it comes to saving and paying for health care with tax-free money. If you have a high-deductible health insurance plan, I would recommend taking a close look at opening a health savings account, or HSA. This is different and ultimately superior to an FSA. So what is an HSA, exactly? And how does it work? Well . . .

How Does an HSA Work?

Most companies offer HSAs to their workers. If yours doesn't, you can set up an account through your insurance provider or brokerage firm. Once you set up your HSA, decide how much to contribute each year. For 2018, the IRS capped contributions at $3,450 for individuals and $6,900 for families.

Like an FSA, an HSA can pay for coinsurance, deductibles, medical equipment, and prescription drugs. You can set up automatic contributions directly from your paycheck, and you’ll be given a debit card, which comes in handy to make copayments during doctor appointments.

Just be aware that there are limits on how much you can withdraw each year to cover qualified out-of-pocket expenses — $6,550 for an individual and $13,100 for a family. Also keep in mind that you can’t use HSA funds to pay your insurance premiums.

HSA Tax Benefits

Like an FSA, contributions to your HSA go into our account pre-tax or are deducted when you file your taxes.

But what really makes HSAs trump FSAs? The contributions can be invested in the stock market and grow over decades. Plus, you don’t have to pay taxes on your withdrawals if you use the money for medical expenses. Tax-free going in, tax-free coming out. Can’t beat it.

Other HSA Benefits and How They Work

To illustrate an HSA’s benefits, let’s compare it to an FSA. For starters, you can only set aside $2,650 pre-tax each year in an FSA. That money can’t be invested, and you must spend the entire balance by year’s end or forfeit it. So you have to predict the future to determine how much to contribute annually.

And there are two other drawbacks: First, you can only start an FSA if you're employed; and second, the contribution amount is locked in for a year.

In contrast, there’s no soothsaying with an HSA, and you can sock away more money than with an FSA. That money is then yours to keep, whether you need it or not. On top of that, the account isn't tied to your job.

You can open one even if you’re self-employed, and you can increase or lower your contribution anytime you wish.

Once you save up enough money, you can go years back to claim reimbursement for certain medical expenses incurred after you had opened your HSA.

Can Anyone Open an HSA?

If you have an FSA, you can’t open an HSA, and vice-versa. But most importantly, you must be in a high-deductible health insurance plan, or an HDHP, to be eligible. For 2018, HDHP deductibles must be $1,350 or more for an individual or $2,700 or more for a family.

And there are other restrictions, too. For instance, you can only have one insurance plan and you can’t be claimed as a dependent on somebody else’s tax return.

Also, if you withdraw money from your HSA before reaching age 65 to pay for non-medical expenses, the Internal Revenue Service will give you a whipping. You’ll have to pay income taxes, plus a 20-percent gross penalty. After age 65, you won’t get slapped with that massive penalty, but you’ll still get an income tax bill.

Final Thoughts

Never pass up the opportunity to get free money from the government. And nothing beats an HSA to do the job. It’s free money when you contribute to it and free money when you withdraw. It’s like having another retirement account.

If you’re lucky, you could start funding your HSA in your 20s, watch its value grow in the investments of your choosing, and not touch it until age 65, when you’ll probably need it most. Experts say that retirees should save at least $250,000 for medical expenses. An HSA is one of the best ways to achieve that goal and more.

Further Reading: Learn more about investing in stocks and using health savings programs.