We can't count on a booming economy to drive consumer spending right now. The coronavirus pandemic continues to weigh on shoppers' paychecks and wallets, and it's unclear how long the health crisis and its aftermath will last.

So now is a perfect time to have a look at your investment portfolio and add companies that can maintain revenue growth, even in such a troubled economic environment. Not only are they good investments right now, but they're solid additions to prepare you for any future recession.

Here are three companies that offer the essentials needed to succeed in a recession: a retailer, a maker of household products, and a pharmaceutical company with a portfolio of potential blockbusters.

A yellow street sign says "recession ahead" in front of a stormy sky.

Image source: Getty Images.

1. Walmart

Walmart's (NYSE:WMT) annual revenue has climbed for the past four fiscal years. The company got a boost this year as consumers stockpiled grocery and cleaning items early in the health crisis and made purchases through Walmart's growing online platform. In the most recent quarter, U.S. same store sales rose 9.3% year over year, and U.S. e-commerce surged 97%. The Sam's Club segment of the company posted a 13.3% year-over-year gain in same store sales and saw a 60% increase in new members.

The grocery and general merchandise giant said several factors contributed to gains: government stimulus checks, the trend of eating at home more often, and focuses on home entertainment, home care, and gardening. Certain elements like stimulus checks may be unique to the current crisis. But others, such as eating and entertaining at home, happen in general during an economic downturn as consumers try to save money. So, Walmart may continue to benefit during future tough times.

Walmart is speeding up its omnichannel investments, and as part of that, is launching same-day pickup and delivery in more stores. This should help Walmart maintain at least some of the digital momentum gained in recent months.

And finally, during good times and bad, investors can count on dividend increases. The company has lifted the annual dividend every year since it first started payment in 1974. The dividend currently is paying out $2.16 per share per year.

2. Clorox

Speaking of dividends, that is one reason to buy shares of Clorox (NYSE:CLX). In May, the maker of cleaning and home care products lifted its quarterly dividend 5% to $1.11 per share. This is the 51st straight year Clorox has paid a dividend. It has raised its annual dividend for 43 consecutive years. And looking at the company's free cash flow situation, we can be optimistic dividends -- and regular increases -- will continue. The company's cash dividend payout ratio shows it paid out 41% of its free cash flow in dividends over the past year. And free cash flow stands at nearly $1.3 billion, the highest ever.

CLX Cash Dividend Payout Ratio (Annual) Chart

CLX Cash Dividend Payout Ratio (Annual) data by YCharts

Beyond dividends, revenue and earnings are another reason to count on Clorox in a recession. The company said in August that it posted an 8% year-over-year increase in sales and a 16% increase in diluted earnings per share for the 2020 fiscal year. In the fourth quarter, sales climbed 22% year over year, led by double-digit volume increases in all businesses. Gross margin expanded to 46.8% from 45.1% year over year thanks to volume growth and cost control. This marks the seventh straight quarter of gross margin gains.

The need for cleaning products during the current health crisis surely is giving Clorox an edge right now. The situation may be different in a future recession that doesn't involve a virus. That said, the fact that Clorox's products are for the most part essentials -- unlike discretionary items that people can postpone buying -- means it's likely this company will continue to grow sales during any economic downturn.

3. Bristol Myers Squibb

Bristol Myers Squibb (NYSE:BMY) holds a portfolio of six blockbuster products. That includes multiple myeloma drug Revlimid that the pharmaceutical company gained through the acquisition of Celgene Corp. last year. Revlimid generated more than $2.8 billion in sales in the most recent quarter, for a 6% increase year over year.

And Bristol Myers Squibb is making regulatory progress with its marketed cancer drug Opdivo. The U.S. Food and Drug Administration approved the drug for five new uses this year. Opdivo already brought in more than $1.6 billion in revenue in the second quarter, though that was down 9% year over year. It's logical to expect a new phase of growth for the drug due to the recent approvals.

A planned acquisition represents another growth opportunity for Bristol Myers Squibb. The company recently said it will buy biotech company MyoKardia (NASDAQ:MYOK). Through the operation, it will gain ownership of mavacamten, an investigational treatment for a chronic heart disease called obstructive hypertrophic cardiomyopathy. Mavacamten met the primary and all secondary endpoints in a pivotal trial, and the next step is a regulatory submission in the first quarter of next year.

A pharmaceutical company is a good bet during a recession because patients must continue treatments for serious diseases regardless of the state of the economy. Therefore, these companies usually can maintain revenue even when times are tough.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.