Home Depot (HD 0.02%) and Lowe's (LOW -0.03%) were beneficiaries of a massive shift in consumer spending at the pandemic's onset. Forced to work, learn, and entertain at home, people spent on home improvement en masse. With major COVID restrictions lifted, consumer spending is shifting again. 

Home Depot and Lowe's latest results reveal that inflation is biting into budgets and slowing sales growth. 

Home improvement sales are slowing as inflation is soaring

Home Depot's fiscal 2022 first quarter ended on May 1. During that period, net sales increased 3.8% year over year to $38.9 billion. That marks a considerable slowdown from the 32.7% top-line growth it logged in the same quarter last year. CEO and president Ted Decker commented, "The solid performance in the quarter is even more impressive as we were comparing against last year's historic growth and faced a slower start to spring this year." People were spending a lot more time indoors during the year-ago period, so they looked to improve their living spaces.  

LOW Revenue (Quarterly YoY Growth) Chart.

Data by YCharts.

Rival Lowe's experienced a similarly drop in sales momentum in its most recent quarter (ended April 29), when it reported sales decreased 3.1% year over year. This time last year, Lowe's posted revenue growth of 24.1%.

So both home improvement retailers have reported a sudden deceleration to their robust growth. That development suggests consumers are shifting their attention (and spending) to other categories like dining and travel. Additionally, the retailers' results indicate inflation is taking its toll on consumer demand overall.

For instance, in its latest quarter, Lowe's reported the average customer transaction value increased 9.3% year over year. Meanwhile, the number of transactions declined 13.1%. Similarly, Home Depot reported average ticket size increased 11.4%, while the number of transactions decreased 8.2%. 

As consumers observe businesses raise prices on everything from home improvement supplies to fuel, they're reining back some of their spending. According to the Bureau of Labor Statistics, the consumer price index jumped 8.3% in April. The U.S. has not seen these levels of inflation in decades. It's not surprising that people are hesitating before pulling out their wallets. 

US Consumer Price Index YoY Chart.

Data by YCharts.

Investors should not panic

That said, investors should proceed with caution. The coronavirus pandemic has created ripple effects, reducing various industries' capacity to meet customer demand. That mismatch between supply and demand has put upward pressure on prices, fueling inflation.

Regardless, when investors try to buy and sell in response to perceived economic changes, market timing is nearly impossible to implement effectively. The superior strategy is to buy a diversified basket of stocks and hold them for five years or longer. Investors should not panic and sell their investments right now.