If there were any lingering worries about the oil downturn's impact on Royal Dutch Shell's (NYSE:RDS-A) (NYSE:RDS-B) future ability to generate returns for investors, this past quarter put a lot of those concerns to bed. The company's earnings continue to post much-improved results, and its cash flows are robust enough that it can start doing things with excess cash. Shell ended 2017 on a relatively high note and marked another milestone in its post-BG Group acquisition strategy. 

Here's a rundown of Shell's most recent quarterly earnings report and a quick look at what investors can expect in 2018.

Offshore drilling rigs at a dockyard at night.

Image source: Getty Images.

By the numbers

Metric Q4 2017 Q3 2017 Q4 2016
Revenue $85.4 billion $75.8 billion $64.7 billion
Net income $3.81 billion $4.09 billion $1.61 billion
Earnings per share (ADS) $0.92 $1.00 $0.38
Cash flow from operations $7.27 billion $7.58 billion $9.17 billion 

DATA SOURCE: ROYAL DUTCH SHELL EARNINGS RELEASE. ADS = AMERICAN DEPOSITARY SHARES.

Despite the fact that earnings this past quarter slipped slightly compared to the prior quarter, and cash flow was a little bit lighter than the previous year's result, this was a good quarter for Shell. Looking at the income statement, the only item that led to this dip in earnings was an extra $1.2 billion in income taxes. Most of that was related to the changes in the U.S. tax code and Shell's reevaluation of its deferred tax assets. On a pre-tax basis, this quarter was a 15.7% gain compared to the prior quarter and the best result since 2014.

Much of the success in recent quarters has been a result of improved earnings for its integrated gas and upstream business segments. That shouldn't come as a surprise to anyone as oil prices have been rising for more than a year. In the fourth quarter, the company had an average realized oil price of $55.28 per barrel compared to $44.54 per barrel the prior year. Higher liquefaction volumes and total liquefied natural gas sales in its gas trading arm also contributed to this past quarter's gains.

RDS earnings by business segment for Q4 2016, Q3 2017, and Q4 2017. Shows greater than $1.5 billion gain for upstream and $700 million gain for Integrated gas, Oil products and chemicals were flat year over year.

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

These quarterly numbers don't do justice to the monumental changes at Shell over the past couple of years, though. If you want to see the difference a year or two can make, you need to back out the lens a little bit. The $6 billion swing in upstream earnings from higher prices and lower breakeven costs were a huge factor, but the additional $1 billion in chemical profits from higher volumes of intermediate- and higher-value products have been a salve for the company's earnings and overall rates of return.

RDS earnings by business segment for 2015, 2016, and 2017. Upstream earnings improved from $2.7 billion loss to $3 billion gain, and Chemical earnings up $1 billion to a total of $2.6 billion.

Data source: Royal Dutch Shell earnings release.

What's more, Shell has been able to achieve these results with a smaller footprint. After the acquisition of BG Group, it has sold close to $30 billion worth of assets that didn't quite fit the portfolio of the combined company. Those proceeds have been used to lower its total debt load by repaying $11 billion of notes outstanding in 2017. At the end of the quarter, Shell had a net gearing ratio (debt minus cash dividend by total capitalization) of 24.8%. That's still a little high compared to its largest competitor, ExxonMobil, but it is more or less in line with the rest of the integrated oil and gas peer group.

As a result, we have a company that has improved its return on average capital employed to 5.8% at the end of this most recent quarter. It still has a lot of work to do to get back to double-digit rates of return it had back in 2012, but it's clearly headed in the right direction again. 

What management had to say

There were some doubts that Shell's management would be able to manage the downturn in the oil industry and the integration of a massive acquisition at the same time. Based on the results, though, it has pulled it off. So, in his press release statement, CEO Ben Van Beurden highlighted some of the successes of this turnaround and announced another step forward in its plan.

Our relentless focus on value, performance and competitiveness meant we were able to deliver $39 billion of cash flow from operations excluding working capital movements from our upgraded portfolio. We strengthened our financial framework during the year through an $8 billion reduction in our net debt, while our increased free cash flow generation gave us the confidence to cancel the scrip dividend programme in the fourth quarter, in line with what we said previously. 

We reported strong earnings for the quarter underpinned by continued delivery momentum. Cash flow reflected higher tax payments and increased cash requirements in relation to our trading business. We enter 2018 with continued discipline and confidence, committed to the delivery of strong returns and cash.

The company's scrip dividend program -- issuing shares in lieu of cash -- has helped keep its dividend afloat during the downturn. So to hear that management has the confidence to stop offering a scrip dividend and pay in cash only is a sign that things are returning to normal.

RDS.B Chart

RDS.B data by YCharts.

What a Fool believes

Shell is positioning itself incredibly well for 2018. With oil prices still on the rise, we can reasonably expect the company's free cash flow to grow even more to support a cash dividend and continue to trim its overall debt load. Management hasn't specified its target net gearing ratio, but it's historically run in the 5%-15% range. The closer we get to that number, we can probably expect it to start buying back stock, which management said it wanted to do to make up for shareholder dilution related to the scrip dividend and BG Group purchase.

The oil market could take a turn at any moment, but based on the current market trends, it appears that Shell looks well suited to reward investors for their patience over the past few years. As it stands, it looks like Shell could be your best bet among the integrated oil and gas companies today. 

Tyler Crowe owns shares of ExxonMobil. The Motley Fool has no position in any of the stocks mentioned. The Motley Fool has a disclosure policy.