All APIs

Spot metals price API

Get gold, silver, platinum and palladium spot prices, plus WTI, Brent and copper reference prices derived from futures markets, not physical spot cargo prices.

Online99.96% uptime, last 30 days357 ms typical response

First request

Get the gold price in US dollars

curl --request GET \
  --url "https://api.narwhalapi.com/v1/commodities/spot/XAU/USD" \
  --header "Authorization: Bearer $NARWHAL_API_KEY"
Example response
{
  "symbol": "XAU-USD",
  "price": "2500.00",
  "currency": "USD",
  "unit": "troy_ounce",
  "timestamp": "2026-08-21T12:00:00Z",
  "stale": true
}

Endpoints

GETGet a spot price/v1/commodities/spot/{commodity}/{currency}

Get a spot price or a futures-based reference price.

Parameters

  • commodityrequired

    XAU, XAG, XPT, XPD, WTI (WTI crude oil), BRENT (Brent crude oil) or XCU (copper).

  • currencyrequired

    The quote currency in capitals. Gold has 31 currencies. The others are quoted in USD only.

The quote

  • symbolstring

    The commodity and quote currency, such as XAU-USD.

  • currencystring

    The quote currency.

  • unitstring

    troy_ounce for precious metals, barrel for WTI and BRENT, and pound for XCU.

  • pricestring

    One positive indicative price as a decimal string.

  • timestampdate-time

    The quote time in UTC.

  • staleboolean

    Whether the quote is stale. A closed market never makes a quote stale.


Full reference →
GETGet price bars/v1/commodities/spot/{commodity}/{currency}/bars

Open, high, low and close bars for gold, silver, platinum, palladium, copper, WTI and BRENT.

Parameters

  • commodityrequired

    XAU, XAG, XPT, XPD, WTI (WTI crude oil), BRENT (Brent crude oil) or XCU (copper).

  • currencyrequired

    The quote currency in capitals. Gold has 31 currencies. The others are quoted in USD only.

  • intervaloptional

    1m, 5m, 15m, 1h, 4h or 1d. The default is 1d.

  • startrequired

    The first bar, as a UTC time on an interval boundary. Inclusive.

  • endrequired

    The last bar, as a UTC time on an interval boundary. Exclusive.

  • limitoptional

    Bars per page. The default is 100 and the most is 500.

  • cursoroptional

    Reuse next_cursor from the previous page with the same query.

Response fields

  • barsarray

    Closed bars from oldest to newest, each with a timestamp and open, high, low and close as decimal strings. Gold in currencies other than USD has close only.

  • next_cursorstring

    The cursor for the next page. Null when no bars remain.


Full reference →

Use cases

Oil price per litre and gallon

Convert Brent or WTI from dollars per barrel to litres and gallons.

Read the guide →

Copper price per kg and tonne

Convert copper from dollars per pound to kilograms and metric tonnes.

Read the guide →

Prices in your currency

Get a commodity price in your own currency, such as rupiah per gram.

Read the guide →

Commodity price indexation

Move a contract price with a commodity index between two months.

Read the use case →

Coverage

Related APIs

Physical commodity prices API

Palm oil, daily oil and gas prices, weekly US retail fuel prices and monthly commodity benchmarks, with units as published.

Explore the API →

Exchange rate API

Current exchange rates, currency conversion and stored rate history.

Explore the API →

Pricing

Free to start. $10 free credits every month, then $2 per 1,000 calls.

See pricing →

FAQ

What unit are the prices in?

The unit field is troy_ounce for precious metals, barrel for WTI and BRENT, and pound for XCU. A troy ounce is not an ordinary ounce.

Which currencies are available?

Gold is quoted in 31 currencies; silver, platinum, palladium, WTI, BRENT and XCU in USD only. The coverage list shows every commodity and currency. An unknown commodity returns 404 commodity_not_supported; a known commodity with an unsupported currency returns 404 currency_not_supported.

What should I check before using the data?

Keep the quote timestamp visible in your application. A stale quote must not be presented as a fresh market price. The daily 17:00 New York metals pause (21:00 UTC in summer, 22:00 UTC in winter) is not a market closure, and quotes during it can carry stale: true. A closed market never makes a quote stale: from Friday 17:00 to Sunday 17:00 New York time you get the last price with stale: false.