GET /v1/prices?symbol=XAU-USD-SPOT gives you the gold spot price in US dollars per troy ounce. Omit symbol to request all spot prices at once. Without a key, the limit is 10 requests a minute per IP. Free and keyless prices are delayed by 15 minutes.
Make a request
Symbols use BASE-QUOTE-CONTRACT, such as XAU-USD-SPOT, XAG-USD-SPOT or XAU-INR-SPOT for gold priced in rupees. Both gold and XAU resolve to XAU-USD-SPOT. Store your key on the server, as the API does not support browser CORS.
curl "https://api.goldprice.dev/v1/prices?symbol=XAU-USD-SPOT" \ -H "Authorization: Bearer $GOLDPRICE_API_KEY"const res = await fetch("https://api.goldprice.dev/v1/prices?symbol=XAU-USD-SPOT", { headers: { Authorization: `Bearer ${process.env.GOLDPRICE_API_KEY}` },})const data = await res.json()if (!res.ok) throw new Error(data.error)import os, requestsres = requests.get( "https://api.goldprice.dev/v1/prices?symbol=XAU-USD-SPOT", headers={"Authorization": f"Bearer {os.environ['GOLDPRICE_API_KEY']}"}, timeout=10,)res.raise_for_status()data = res.json()Request parameters
| Name | Location | Required | Description |
|---|---|---|---|
symbol | query | No (every spot price) | BASE-QUOTE-CONTRACT, such as XAU-USD-SPOT |
include | query | No | Additional field groups, such as sources,karat or all |
Read the response
This example response was recorded without a key on 19 Oct 2026. Prices use strings to preserve precision. Parse them as decimals.
{ "symbols": [ { "symbol": "XAU", "quote_currency": "USD", "unit": "troy_ounce", "contract_type": "spot", "price": "4164.22", "is_stale": false, "computed_at": "2026-10-19T12:45:06.720397+00:00" } ]}| Field | Description |
|---|---|
symbol | Metal code: XAU, XAG or HG |
quote_currency | Currency used for the price |
unit | troy_ounce, or pound for copper |
contract_type | spot |
price | Price as a decimal string |
is_stale | True if the price is outside its freshness window |
computed_at | Price calculation time (UTC) |
API errors
| Status | error | Cause |
|---|---|---|
| 400 | invalid_symbol | Symbol is unavailable or does not use BASE-QUOTE-CONTRACT |
| 429 | rate_limited | Keyless IP exceeded 100 requests in the hour |
| 429 | rate_limit_exceeded | Minute limit exceeded for the plan, or per IP without a key |
| 429 | quota_exceeded | Plan's monthly request quota exceeded |
{ "error": "invalid_symbol", "symbol": "NOPE", "hint": "expected format BASE-QUOTE-CONTRACT, e.g. XAU-USD-SPOT"}Request and data limits
Free and keyless prices are delayed by 15 minutes. Without a key, you get 10 requests a minute per IP. A free key includes 5,000 requests a month. Paid plans provide live prices. See free plan limits for all plan limits.