Stocks go up and stocks go down, but the one thing you can count on is this: Prices of just about everything you'll need after you retire will go up over time. The challenge is figuring out how to make your retirement investments grow enough to keep up with the rising prices of your basic necessities. But with a little work, you can find the best ways to beat inflation -- and they aren't necessarily where you might expect.

Why inflation is a money-killer
When you talk about ways to lose money, most investors immediately think of stocks prices dropping like a stone during bear markets. The impact that stock declines have on your net worth is obvious: Your brokerage statements tell the tale each and every quarter. When bear markets strike your investments, you'll know about it.

Inflation often isn't that straightforward. Occasionally, big moves like we've seen in oil and food prices lately make it all too clear just how painful rising prices can be. But even the more gradual pace of inflation is enough to reduce the purchasing power of your portfolio considerably over time -- and more importantly, you have to keep your eyes on a moving target if you want to be certain that you'll be able to afford everything you want after you retire.

The obvious inflation plays
Because inflation has been a constant threat for so long, financial products evolved to help fight its effects. In particular, the U.S. Treasury came out with its inflation protected securities, or TIPS, which are bonds whose principal value is indexed to inflation and changes with the Consumer Price Index.

Investors who want to own TIPS have several options. The TreasuryDirect service sells them directly to the public, and many discount brokers allow you to buy TIPS at auction for little or no cost. In addition, mutual funds and ETFs such as iShares Barclays TIPS Bond (NYSE: TIP) and SPDR DB International Government Inflation-Protected Bond (NYSE: WIP) give you a full diversified portfolio of TIPS and similar instruments from governments around the world.

Another way those in or near retirement can fight rising prices is to buy immediate annuities whose payouts are linked to changes in inflation. Again, these annuities typically use the CPI as a reference point, but by making sure your payouts will rise generally with overall costs, you'll put yourself in a better position to outlast your money and preserve its purchasing power.

Finally, a traditional way that many investors have struggled against inflation is by buying gold. Many remember gold as a lucrative investment during the late 1970s, when double-digit inflation posed a major threat to the U.S. economy. Although it fell out of favor after inflation levels subsided, the popularity and ease of use of the SPDR Gold Trust (NYSE: GLD) ETF, along with big jumps from the yellow metal's lows from 10 to 12 years ago, have helped gold recover its reputation as a method for fighting inflation.

Build a better link
But the way I prefer to fight inflation addresses a key argument against CPI-linked measures: that the CPI doesn't accurately reflect a person's own experience of rising prices. Although the CPI is an aggregate measure, everyone's individual tastes lead to a different effective rate of inflation. If you like specialized products, the CPI is unlikely to reflect the price behavior you see in the things you buy.

The key, then, is to connect what you need with investments that prosper when your necessities rise in price. For instance, if you need to protect against higher energy costs, then investing in energy giant Chevron (NYSE: CVX) or a broader-based fund like the Energy Select SPDR (NYSE: XLE) should help you match higher prices with rising share values.

But what if prices fall? Those stocks might get hurt, creating losses in your investment portfolio and offsetting the benefit you'll get from lower costs for your everyday needs. Still, many retirees might consider that risk worth it in order to hedge against the possibility of wallet-busting price increases.

Get personal
Investing with inflation in mind isn't as simple as it looks. But if you take the time to see what you'll truly need after you retire, you can tailor your portfolio to move up and down with the prices of those necessities. That should give you peace of mind you can't get from any other investment.

Now more than ever, starting a watchlist can help you keep track of all your investments. Add any company or ETF you want and start getting valuable updates on the latest news about your favorite investments. Also, you'll get immediate access to a new special report, "6 Stocks to Watch from David and Tom Gardner." Click here to get started.

Fool contributor Dan Caplinger likes to win a fight. He doesn't own shares of the companies mentioned in this article. Pfizer is a Motley Fool Inside Value selection. Chevron is a Motley Fool Income Investor pick. Try any of our Foolish newsletter services free for 30 days. We Fools may not all hold the same opinions, but we all believe that considering a diverse range of insights makes us better investors. The Fool's disclosure policy never loses its keys.