Procter & Gamble (PG -0.03%) and Unilever (UL 5.93%) (UN) have long been the two companies that have most defined the household goods space, dominating categories like detergent, soap, deodorant, and condiments, to name only a few.

Both companies date back to the 1800s and have established global distribution chains and the marketing muscle to back them. Popular brands include Tide, Crest, and Pampers for P&G, and Ben & Jerry's, Dove, and Hellmann's for Unilever.

Like much of the consumer staples sector, Procter & Gamble and Unilever offer solid dividend yields, but as defensive stocks, they have lagged the broader market during the rally in recent years. You can see how the stocks have performed over the past five years from the chart below.

UL Chart

UL data by YCharts.

The spike above in Unilever in 2017 came as Kraft Heinz, with the backing of Warren Buffett, offered to buy the company. Unilever rejected the deal, but the stock nonetheless remained elevated. Aside from that event, the two stocks have been mostly flat over the last five years. Let's take a look at where the two consumer products companies stand today and which one is the better investment.

Two people compare detergents in a supermarket aisle.

Image source: Getty Images.

A slow transition

Procter & Gamble has been in the midst of a significant change in strategy recently, selling off smaller brands in order to narrow its focus and invest in its most important money makers. The company sold Duracell to Warren Buffett's Berkshire Hathaway, it shipped off Cover Girl and dozens of other cosmetics brands to Coty, and it sold Iams and other pet-food brands to privately-held Mars.

While those moves may have eliminated distractions and levels of bureaucracy, allowing the company to devote more attention to leading brands like Gillette and Tide, growth has nonetheless been slow. In fiscal 2018, which ended this June, net sales increased 3%, and organic sales, which strip out the effect of acquisitions, divestitures, and foreign exchange, rose just 1%.

P&G appears to be struggling with competition from small niche brands, which have proven attractive to millennials and have found ample advertising opportunity in the era of social media and e-commerce. In the organization's grooming division, for example, organic sales fell 3% in its most recent quarter, as its Gillette brand faces competition from upstart online brands like Dollar Shave Club—which is now owned by Unilever—and Harry's.

Core earnings per share (EPS) grew 8% over the fiscal year, but with just modest sales growth -- EPS improvement was mostly a product of lower sales, general and administrative expenses, a lower tax rate, and fewer shares outstanding due to share buybacks. For fiscal 2019, the company sees core EPS growth of 3-8%, which is unlikely to fire up a stock currently valued at a price-to-earnings (P/E) ratio of 22.7.

Leaning toward innovation

Like Procter & Gamble, Unilever has reported slow growth recently. As household-products multinationals face several growth headwinds, the company has been more focused on expanding its portfolio rather than shrinking it as P&G has done. The company has made several acquisitions in recent years, including Dollar Shave Club, ketchup maker Sir Kensington's, Tazo, and Seventh Generation. Unilever also appears to be thinking creatively about new products, recently launching Day 2, an aerosol spray meant for lightly worn clothes that often end up on bedroom chairs.

Nonetheless, growth has been similarly modest for Unilever, as sales, which increased 2.7% through the first half of the year, were affected in part by a Brazilian trucker strike. However, Unilever posted improvement in profitability, as gross margin increased 60 basis points to 43.7%, and constant-currency earnings per share rose 18.6%. The company also expects sales to improve in the second half of the year: Management is targeting 3-5% sales growth and improvements in underlying operating margin and free cash flow. Historically, Unilever has also had a better return on invested capital than its rivals. The company has a nearly identical P/E valuation to P&G at 22.3.

The key numbers

In addition to the similar price-to-earnings valuations, P&G and Unilever track each other on key metrics like dividend yields. P&G offers a 3.5% yield compared to 3.3% for Unilever. Procter & Gamble is a Dividend Aristocrat while Unilever is not, but Unilever has grown its dividend faster in recent years. Unilever also has a lower payout ratio at 72% against 78% for Procter & Gamble, and is growing earnings faster.

Taking into account Unilever's forward-looking acquisitions of environmental and niche brands designed to appeal to younger customers, as well as the interest from Kraft Heinz, past performance, and the numbers above, it looks like the better bet. Though I wouldn't expect either of these stocks to run ahead of the major indices as long as the stock market expansion continues, Unilever seems poised to outperform its rival over the coming years.