Image source: Getty Images.

After an eye-popping rally that lasted almost seven months, gold stocks started reversing trend sometime around August this year. With nearly every gold stock deep in the red since, value-minded gold investors might consider investing in some top names like Barrick Gold (GOLD 0.71%) and Royal Gold (RGLD 0.88%). But which of the two stocks is a better buy today? Royal Gold's less risky business model and Barrick's dominance as the world's largest gold miner make for an interesting face-off, so let's find out which stock deserves greater attention now. 

The battle of margins

Both Barrick and Royal Gold give you 100% exposure to the yellow metal, but there are huge differences between the way the two companies operate and the level of risk their businesses are exposed to.

Barrick is a traditional gold miner -- it extracts gold from mines to sell in the market. So it makes money when gold prices rise, and loses when they fall. Royal Gold's profits also, of course, rise and fall with gold prices, but the company makes bigger profits for two reasons: It doesn't any incur mining costs, and it gets bullion at low rates. That's because Royal Gold doesn't own or explore any mines, but buys precious metals from other miners at fixed costs in exchange for up-front funding.

For example, Royal Gold paid $610 million cash to Barrick last year in exchange for the right to buy a certain percentage of gold and silver at 30% of spot prices, up to a certain threshold, and then at 60%. So at any point in time, Royal Gold will secure bullion under this agreement at least 40% below market price. This example highlights two interesting and important aspects of Royal Gold's business: First, a competitor like Barrick is also a partner; and second, Royal Gold's purchase cost of precious metals is substantially below market prices, which explains the company's best-in-the-industry margins.

RGLD Operating Margin (TTM) Chart

RGLD Operating Margin (TTM) data by YCharts.

Moreover, Royal Gold has clocked a 63% jump in revenue in the past five years, absolutely crushing Barrick, which saw its revenue slump almost 40% during the period. So when it comes to operational performance, we have a clear winner here: Royal Gold. The remaining question is whether shareholders are being rewarded.

Which company offers a better dividend: Royal Gold or Barrick?

While you can understand how Royal Gold wins on the cost and margin fronts, Barrick's position in the industry can't go unnoticed either. Barrick is among the lowest-cost gold producers in the world today, which is a huge competitive advantage to have in a volatile business like gold mining. Barrick is now targeting full-year all-in sustaining costs -- a key cost metric for gold miners -- of only $740-$775 per ounce. That's roughly 7% improvement from 2015 levels even at the higher end of the range. Most publicly traded large gold miners are struggling to stay below $850 per ounce.

So how is Barrick pulling it off? It's taking a fourfold approach: aggressive cost-cutting, divesting of noncore assets, focus on low-cost mines, and deleveraging. Barrick is clearly serious about improving efficiency, which is a smart move that should help it grow its cash flow even during adverse business conditions. Then again, the growth in Barrick's cash flow in the past five years pales in comparison to Royal Gold's, and it's difficult to say if Barrick can ever take the lead given Royal Gold's inherent advantage -- low fixed costs.

RGLD Cash from Operations (TTM) Chart

RGLD Cash from Operations (TTM) data by YCharts.

In fact, the predictable nature of Royal Gold's cash flow has enabled it to increase its dividend every year for 16 straight years, with the latest hike of 4% coming just a couple of weeks ago. In sharp contrast, Barrick has slashed its annual dividend to $0.08 per share from $0.75 a share in 2012. That's a steep 90% cut. Barrick may be able to maintain, and even grow, its dividends going forward as it strives to boost cash flow, but there's no denying that Royal Gold's dividends are far more secure and reliable. Another point to note: If you'd invested in Royal Gold 10 years ago, your money would've more than doubled by now. With Barrick, you'd have lost almost half your money.

The verdict: This stock will pull you through volatility

Its hold in the industry and its ongoing efforts to turn around make Barrick a compelling bet, but when you pit the company against Royal Gold, the latter edges out Barrick in every key area that should matter to an investor. While past performance does not guarantee future returns, Royal Gold's streaming business should continue to leverage investors to precious metals at low risks. A consistent dividend adds an extra layer of security, which matters a lot when you're investing in a volatile area like gold.