Oil prices are surging this year, and the last decade shows that several energy stocks have performed well during similar periods of rising crude prices.
The outperformers run the gamut, from refiners like Andeavor and Phillips 66, to independent U.S. drillers like Concho Resources and Pioneer Natural Resources, down to drilling contractors like Helmerich and Payne.
On Thursday, U.S. West Texas Intermediate crude hit a 3½-year high at $72.30 and was up about 15.6 percent over a three-month period.
Across 16 similar oil prices environments, refining company Andeavor — previously known as Tesoro — has the been the best performer in the aggregate, according to hedge fund analytics tool Kensho. Shares of Andeavor, which operates refineries and oil infrastructure in the western United States, traded positive 75 percent of the time and gained an average 17.1 percent, the Kensho study showed.
The next best performer was Concho Resources, a driller focused on the Permian Basin in Texas. The stock returned an average 16.2 percent across the 16 instances and traded positive nearly 94 percent of the time, according to Kensho.
Another refiner, Phillips 66, ranked third in the Kensho study, returning an average 15.1 percent and trading positive 90 percent of the time.
Helmerich & Payne stock returned 14.6 percent in the study, while shares of Pioneer Natural Resources were up 14 percent.
There's no guarantee that oil prices will keep rising, but when it does, these stocks have a history of breaking out.
The results are based on 16 instances when oil prices rose more than 10 percent over the course of three months. Across those cases, WTI was up about 15 percent on average.
Disclosure: CNBC's parent NBCUniversal is a minority investor in Kensho.