2017 has been a fantastic year for Royal Dutch Shell (RDS.A) (RDS.B). The company's financial results don't come anywhere near the results it posted four or five years ago, but the fact that it can produce the results it has in this oil and gas environment is a testament to management's decision to tackle its cost structure and its spending habits. 

This quarter was a bit of a milestone for the company as it was able to produce pre-crash levels of cash flow with oil prices only half what they were then. Let's take a look at Shell's most recent financial performance and what investors can look forward to in the coming quarters. 

offahore oil rigs at port.

Image source: Getty Images.

By the numbers

Metric Q3 2017 Q2 2017 Q3 2016
Revenue $75.8 billion $72.13 billion $71.79 billion
Net income $4.09 billion $1.54 billion $1.37 billion
Earnings per share (ADS) $1.00 $0.38  $0.86
Cash flow from operations $7.58 billion $11.28 billion $8.59 billion

Data source: Royal Dutch Shell earnings release. ADS = American Depository Shares.

Perhaps it's time to stop thinking about Shell as the industry laggard when it comes to generating returns for investors, because the recent string of results has shown a marked improvement. The first number that stands out here is the increase in net income to $4.09 billion. That was the best quarter Shell has had since the third quarter of 2014, and that was when the average price of Brent crude oil was $107 per barrel.

It's a testament to the cost-cutting and portfolio management Shell has undertaken during this downturn to reduce its breakeven price and improve the performance of its downstream assets. The only reason cash flow from operations doesn't look quite as robust as net income is because it had a $2.5 billion build of working capital in the quarter. 

Looking at Shell's various business segments, not one stood out as performing better than the others because they all put in a respectable quarter. Oil and gas price realizations were up, refining margins for its oil products increased, and chemical margins remained consistent. While it would be more encouraging if some of that better performance came from higher production or new downstream assets, it was a welcome improvement over the prior year. 

RDS earnings by business segment for Q3 2016, Q2 2017, and Q3 2017. Shows improvement for all segments.

Data source: Royal Dutch Shell earnings release. Chart by author.

Management continued to execute its primary goal of reducing debt in the quarter by retiring $2.4 billion in total debt outstanding. However, the company burned through some cash to do it, so the company's overall operating leverage metrics stayed about the same. As it stands, Shell's net debt is at $67.6 billion and a net gearing of 25.4%.

What management had to say

In her press release video, CFO Jessica Uhl focused on how the company continues to improve its cash position:

[O]verall, we continue to drive our four performance levers to manage the financial framework: divestments, capital expenditure, operating expense and new projects.

These levers are adding significantly to our cash flow. On a 4-quarters rolling basis we have generated some $27 billion of free cash flow, including around $11 billion of cash proceeds from divestments. 

To date we have completed $20 billion of divestments including the sale of our North Sea and Gabon assets completed this week. We are on track to meet the target of $30 billion of divestments between 2016 and 2018. We are demonstrating good delivery against our four levers and I want to further strengthen the momentum, with a strong focus on performance management, simplicity, and costs.

What a Fool believes

If there were any doubts about Shell's ability to shed its label as a lower return business, this quarter likely squashed them. Another $10 billion or so in debt reduction from its divestments should put the company in a much better position to return capital to shareholders through its dividend -- which it can cover with cash today -- and share repurchases it intends to do down the road.

There's no absolute certainty when it comes to the where the oil and gas market will go from here, but Shell looks much better prepared for any potential downturn and could benefit nicely from higher oil and gas prices.