Solar stocks had a pretty rough week last week. First Solar (FSLR -2.09%), SunPower (SPWR -2.17%), JinkoSolar (JKS -0.14%), and Enphase Energy (ENPH -2.57%) all fell double-digit pergentages last week, and SolarEdge Technologies (SEDG -3.93%) was close. Investors may be wondering what's going on with the industry. 

The drop came despite a lack of bad earnings or subsidy news. But there was one commodity that affected solar stocks a lot, and it may present a buying opportunity for long-term investors

FSLR Price Chart

FSLR Price data by YCharts

Natural gas is to blame

Commodities can have a big impact on trading across the energy sector. Over the last 10 days, oil has been fairly flat, but natural gas prices have fallen 11%, and that's what traders are keeping an eye on.

As the closest competing energy source, natural gas price declines would seem likely to have a significant effect on solar energy. But the cost of natural gas may not have the impact you think. 

Solar power plant in the desert.

Image source: First Solar.

Take one big step back

From a trading perspective, it's easy to make a direct correlation between natural gas prices and solar stocks. If natural gas power plants are competing with solar power plants in the utility market, it makes sense that solar developers would see less demand. But natural gas fuel is only a fraction of the cost inputs for power plants, and long-term the price of natural gas has done little to move the needle for solar energy. 

Below, you can see that over the past decade the price of natural gas has fallen nearly 30% as solar energy production has jumped 13 times. 

Henry Hub Natural Gas Spot Price Chart

Henry Hub Natural Gas Spot Price data by YCharts

Over a long period of time, the downward trend of solar energy production costs overwhelms any change in fuel costs. And that's ultimately what's going to drive solar adoption. 

Should solar stocks be dropping? 

The stock market can swing wildly short-term for a lot of reasons, but if we take a look at 2019 overall, it's been a great year for solar stocks. Here is the same chart as above, but zoomed back to the year-to-date change in share prices. 

FSLR Chart

FSLR data by YCharts

The underlying trends in the solar industry are very good, with installations rising, margins improving as costs come down, and consolidation leaving a bigger piece of the pie for the industry's winners. Those are the trends investors should watch, and they're pointing to an improved profit profile in the solar industry long-term. But short-term, results will be choppy, and so will solar stock prices. 

Last week's move is an example of why we advocate for a long-term investing view at The Motley Fool. If you panicked over moves like the ones last week, you may have missed the outstanding year solar stocks have had, and may not see the long-term opportunity in the industry.