Jessica Dickler

CNBC

Many Americans are woefully ill-prepared for an unplanned expense, so much so that a whopping 66 million U.S. adults have zero dollars saved for an emergency, according to a new study.

When broken down by age, those in Generation X fared the worst: One-third of people ages 36 to 51 said they had saved nothing in anemergency fund. That compares with 27% of all others ages 18 or older, according to a Bankrate.com survey of 1,000 adults conducted earlier this month.

Generally, the likelihood of having saved at least six months of expenses increases steadily after age 25, Bankrate said. Yet for Gen Xers, "those are the years when it catches up with you," said Bankrate's chief financial analyst Greg McBride.

What's this? You can cut your taxes by sending the kids to summer day camp

"This underscores the fact that it takes time, especially because expenses grow faster than many Americans can save during the homebuying, family-raising years," McBride said. "If you are not in the habit of saving regularly, whatever you have is going to get wiped out sooner rather than later."

"Expenses grow faster than many Americans can save during the homebuying, family-raising years."-Greg McBride, Bankrate.com chief financial analyst

Currently, 47% of Americans said they either could not afford an emergency expense of $400, or would cover it by selling something or borrowing money, according to a separate report by the Federal Reserve Board's Division of Consumer and Community Affairs.

College 'victory laps' can cost families an extra $300,000

McBride recommends having at least six months' worth of expenses saved in an emergency fund. Just 28% of Americans have saved that much, the study said, although that's an improvement from last year's 22%.

"Accumulating emergency savings requires establishing the habit," McBride said.

To get there, Katharine Perry, an associate financial consultant at Fort Pitt Capital Group, in Pittsburgh, suggests putting $20 from every paycheck into a savings account.

Ignoring your employer's benefits can cost you big time

"A little bit every month will ensure you are not stressing your cash flow," she said. Otherwise, any sudden expense, from car repairs to a burst pipe, could cause you to slide into debt, she said.

© CNBC is a USA TODAY content partner offering financial news and commentary. Its content is produced independently of USA TODAY.