Once you retire, you'll need money to pay your bills -- and you can't count on Social Security to provide all of it. The average senior on Social Security today only collects a little over $18,000 a year, and chances are, that's not enough to live on.

Enter your retirement savings. The money you sock away in an IRA or 401(k) could supplement those benefits nicely so you're able to live comfortably as a senior. But how much should you be saving?

It's a tough question to answer. The amount of savings you'll need in retirement will depend on a number of factors -- your lifestyle choices, your city or state of residence, and your personal goals. But it may help you to know what your peers are saving en route to retirement so you can get a sense of whether you're on track.

Smiling man in kitchen holding mug

Image source: Getty Images.

With that in mind, Personal Capital recently conducted a survey to see how much money workers of different age groups had managed to sock away. It found that the median retirement plan balance among 40-somethings was $239,095.

To be clear, you shouldn't take this data point to mean that if you don't have a comparable retirement plan balance, you're in big trouble. This number is based on a single survey, and we don't know how much its respondents earn, on average, and what their plans are for the future.

But here's what we do know: By the time you reach your 40s, you should have some money socked away for retirement. And if you don't have around the equivalent of your annual salary saved up, then it would pay to try to ramp up.

How to boost your retirement savings

If you're not satisfied with your retirement savings balance in your 40s, here's some good news -- you may not be retiring for another 20 to 25 years. That gives you plenty of time to catch up and build a sizable amount of wealth.

To get started, examine your spending. Are you blowing money on things you could do without? If so, that's cash that can, and should, go right into your retirement plan.

Next, think about getting a second job. It's not ideal, but if you want to boost your savings rate, you'll need to either spend less or earn more. If you're only willing to cut back on so many expenses, then getting a second job could be your best bet.

Finally, invest all of the money you are able to save wisely. For a 40-something, that means going heavy on stocks. Though stocks are volatile, they can also lead to tremendous growth.

Case in point -- if you manage to set aside $500 a month in an IRA or 401(k) for the next 25 years, and you invest that money in stocks, you might score an average annual 8% return on your investments, since that's a bit below the stock market's historical average. Your ending balance? About $439,000. And that assumes you're starting with nothing.

While it may be helpful to know how much money your peers have managed to save for retirement, the data point above should serve as motivation more so than shame. If you don't have anywhere near $239,095 set aside for retirement, don't beat yourself up. Instead, figure out how much money you'll need to enjoy your seniors years, and then take steps to build a nest egg that will serve you well once you're ready to leave the workforce behind.