Earnings results like the set Phillips 66 (NYSE:PSX) delivered Friday for its second quarter are the kind that get investors to sit up and pay attention. The oil refiner and petrochemical manufacturer's earnings per share of $2.84 exceeded Wall Street's expectations by 25%, propelled by a favorable refining environment. I'm sure there are lots of happy Phillips 66 shareholders out there today, and investors who haven't looked at refining stocks for a while may be considering opening new positions.

For those considering such an investment, let's take a look at the company's results to see what went right in Q2, and whether it can maintain its growth pace for long. 

Pipelines leading to an oil refinery.

Image source: Getty Images

By the numbers

Metric Q2 2018 Q1 2018 Q2 2017
Revenue $29.7 billion $24.0 billion $24.5 billion
EBITDA $2.3 billion $1.16 billion $1.27 billion
Diluted EPS $2.84  $1.07 $1.06
Operating cash flow $2.36 billion $488 million $1.87 billion

Data source: Phillips 66 earnings release. EPS=earnings per share.

Pretty much all of Phillips 66's improvements in Q2 can be chalked up to its higher refining margins. Like many of its peers, the company was able to take advantage of price discrepancies for various types of crude oil. For example, pipeline constraints for Canadian crude have left it significantly cheaper than oil imported from other places. Phillips 66 just happens to have the ability to process more of that particularly type of crude oil than any of its independent refining peers. As a result, the company was able to realize refining margins of $12.28 per barrel this past quarter. It also helped that the company was able to run all of its refineries at a 100% utilization rate -- compared to 89% in the prior quarter -- thanks to a total lack of downtime for turnaround and maintenance. 

PSX earnings by business segment for Q2 2017, Q1 2018, and Q2 2018. Shows large spike in refining earnings.

Data source: Phillips 66 earnings release. Chart by author

Management is looking to keep these refining margins high by investing heavily in its midstream logistics business. A large chunk of its capital spending is earmarked for its subsidiary, Phillips 66 Partners (NYSE:PSXP), which is investing in several new assets such as pipelines and terminals that will either connect Phillips 66 refineries with other cost-advantaged crude oil sources or increase its export capacity for refined products. 

What management had to say

Oil and gas transportation and infrastructure in the U.S. has been a major bottleneck for producers lately, as output growth is exceeding the rate at which the industry can build new pipelines. Not only does that translate to high margins for Phillips 66, but shipping rates on pipelines are incredibly high today, which has investors clamoring to get ownership of these pipes. 

When asked on the company's conference call whether it would make sense to acquire some pipeline assets to take advantage of these mispriced feedstocks, CEO Greg Garland wasn't too keen on the idea.

I think we, like everyone else, kind of looks at everything that's out there, things look really pricey to us, particularly in the midstream space. As you think about the opportunity to create value, we have such a great organic profile in front of us that we don't feel like we need to rush out and do something in terms of the M&A space today. So we'll continue to watch it. If we can create value by doing it, we're certainly willing to do it. We've got the balance sheet and the capability to do it if the right opportunity happens to come our way.

Considering the high demand for takeaway capacity from places like the Permian Basin these days, it makes a lot more sense to build new pipelines than buy into existing ones. Phillips 66 Partners is currently in the process of constructing the Grey Oak pipeline, which will have the capacity to deliver 800,000 barrels per day of crude oil from the Permian Basin to multiple demand hubs in the Gulf Coast, including Phillips 66's massive refining complex in Sweeney, Texas.

You can read a full transcript of Phillips 66 conference call here

PSX Chart

PSX data by YCharts

A fluke or the future for refining?

Earnings results like those that Phillips 66 just delivered naturally get investors excited. Fat margins can pad a company's bottom line, and Phillips 66 has shown to be capable of operating with efficiency consistently. But the question that must be asked is whether these results were a one-off, or an indication of things to come?

Chances are, the answer is somewhere in the middle. No investor should expect Phillips 66 -- nor any refiner -- to sustain refining margins this high. The business is cyclical and volatile -- certain to experience big ups and downs. Less than two years ago, companies in the industry were slogging through a period of incredibly low refining margins that made profits very hard to come by. 

That said, the refining industry in North America has changed quite a bit in recent years. Fast-growing oil production in the U.S. has resulted in domestic crude prices that are cheap relative to the international benchmarks, and refiners with access to cheaper crudes can realize higher-than-industry-average margins. Also, new regulations on certain refined products globally will increase demand for exports, because North American refiners are among the relative few that can produce products to the new specifications. Also, Phillips 66's investments in high-demand centers such as transportation, logistics, and petrochemical manufacturing should help to boost its bottom line.

I don't think we can say that the second quarter defined a "new normal" for Phillips 66, but the environment for refining will be much more in its favor over the next several years. In consequence, I wouldn't put it past the company to churn out a long string of impressive earnings results. 

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.