For the past few months, it seems like no conversation about the economy is complete without someone mentioning a recession, whether trying to predict it or expressing their fears about one. There are different ways to measure whether we're in a recession, but regardless of which you're going by, there's no denying there's a lot of uncertainty. Even so, you don't want to lose sight of your financial goals and the role investing plays in achieving them.

Here's how you should invest during these uncertain times.

You never want to be underprepared

Whether a recession is coming or not (some metrics say we're in one now), the one thing you want to do is focus on what you can control. You can't control the greater economy, but you can control how you prepare. It's much better to be overprepared than underprepared. The first step in getting prepared -- even before investing -- is making sure you have an emergency fund set aside.

If you're single and only responsible for yourself, your emergency fund should be at least three months' worth of expenses. If you have a family, you should aim to have at least six months' worth.

Two people putting coins into a piggy bank.

Image source: Getty Images.

Blue-chip companies are your friend

There are no guarantees in the stock market, but historical performance has proven to be a good indicator of future performance. That's how some companies get to be designated as blue-chip stocks. Blue-chip stocks are well-established, proven companies that are household names and leaders in their respective industries. Blue-chip companies run quality businesses and provide great value to their shareholders with consistent dividend payouts (and increases) and a history of great long-term returns.

Blue-chip stocks should be a part of every investor's portfolio, but they can be extra useful during stock market down periods and economic uncertainty. For decades on decades, blue-chip stocks have proven they can weather bad economic storms and still provide value, so there's no real reason to believe now is the time they'll let investors down.

That's by no means to say everything is and will always be peachy keen with blue-chip stocks, but if you're anxious about what's happening in the economy, it's helpful to lean on companies with proven track records and healthy bank accounts. Investing in a blue-chip exchange-traded fund (ETF) can also help spread out your risk. Many of these ETFs are low cost and give investors the added benefit of diversification.

Remain consistent no matter what

There's conventional wisdom in the stock market that has stood the test of time -- and for a very good reason: It's true. One example of this wisdom is that trying to time the market is a fool's game and virtually impossible to do consistently in the long run. It's easier for investors to be consistent during bull markets because the thought is often "let me make sure to invest now while prices are going up" versus "prices are dropping, so I'll wait until later to invest since stock prices will be lower." 

In theory, it makes sense not to pay $200 for a stock if the price will be $150 down the road. However, the problem is that nobody can predict what the stock market will do. Not me, not you, not Warren Buffett -- nobody. And even if you're right, it sets a bad precedence -- one that will surely come back to haunt you at some point in your investing journey.

One of the best ways to ensure you remain consistent with your investing and not try to time the market is by using dollar-cost averaging. When using dollar-cost averaging, investors set an investing schedule and stick to it no matter what. If you commit to investing $500 every other Monday, then every other Monday, you need to be making that $500 investment regardless of stock prices at the time.

Consistency is how you build wealth in the stock market. Keep your long-term goals in mind and stay the course.