Inflation is often a byproduct of a bustling economy. Prices rise, and so do workers' wages. Sometimes, profit margins climb, too, as companies raise prices even more because of increased demand.

Meanwhile, to combat inflation, our friends at the Federal Reserve often raise interest rates, while various banks and lenders often raise rates on their own. When rates rise, mortgages get more expensive. That can slow homebuilding, which can slow the economy, which can bring inflation down again. Higher rates also mean that it's more costly for companies to borrow money, so they're likely to see their growth slowing, too.

And that's why many people think inflation is bad for stocks.

The prices of existing bonds tend to fall in such a situation, because they offer older, lower interest rates. But when interest rates begin to rise, bonds become more attractive to investors, since they offer higher rates. And as new bonds become more attractive, stocks can become less attractive -- bond returns are typically more reliable, after all.

Not so fast ...
This is all why investors can become skittish when inflation rises. They see the specter of rising interest rates and a slowing economy. These might be faulty expectations, though. For one thing, remember that rising inflation is often (though not lately) tied to a dynamic, growing economy. That's good for the stock market, because it's likely to also be a time of robust revenue and earnings growth for companies.

In the International Herald Tribune, Paul Lim recently explained that although inflation can depress the future value of earnings, it also permits companies to raise their prices. He points to analysis from Merrill Lynch showing that, more often than not, the S&P 500 made gains during inflationary periods.

On the other hand, too much inflation may not be ideal. Lim also cited a study by Standard & Poor's, suggesting that when inflation is between about 2% and 4%, the S&P 500 tends to grow, and vice versa. Historically, that's where inflation has tended to be. It's also auspicious for stocks if inflation is falling, no matter from what level.

What to do
So what should we investors do? Well, we could pay a little attention to inflation -- it had crept upward over the past year, but the latest numbers show it moderating, as a result of lower energy costs. We might simply relax and remember that stocks tend to rise whenever inflation is in its usual range. But we could also have a backup plan ready, should inflation start rising and reach economically challenging levels.

Certain investments, for example, are thought of as "inflation-proof," or at least good for fighting inflation. One of them is gold, though I'd warn you that it's not generally the best investment. Learn more in this argument for gold, this argument against it, and in this duel over gold.

Others recommend commodities, since their prices will rise along with inflation. Well ... maybe. Read this story to find out why you might want to think twice about them. Another option you might consider is Treasury Inflation Protected Securities, also called TIPS, which are especially helpful for your retirement savings.

Stocks for inflation
Finally, there are good old stocks. Remember, they don't always behave alike. Some companies are more able than others to raise their prices in an inflationary environment. Consumer-product companies, for example, such as Kraft Foods (NYSE:KFT), General Mills (NYSE:GIS), Procter & Gamble (NYSE:PG), and Campbell Soup (NYSE:CPB), all enjoy consumer demand that stays relatively constant regardless of the economic condition. Companies that make things like washing machines and cars -- think Whirlpool (NYSE:WHR) and Ford (NYSE:F) -- are less able to raise prices quickly, because consumers can easily put off purchasing their bigger-ticket offerings.

Dividend-paying stocks are also well worth considering. Altria (NYSE:MO), for example, sports a dividend yield well above 6%. That yield alone is likely to outpace inflation for you, and on top of that, you can look for stock-price appreciation over time. Over the past years, I've added a bunch of steady, growing dividend payers to my own portfolio. They're great whether you're facing inflation worries or not.

So don't let inflation intimidate you. Just make sure your portfolio is set up to take advantage of it.