Free Commodity Price API
Data, Limits & Examples
Find a usable free commodity price API for gold, oil, metals, energy, and agriculture—then verify freshness, history, units, quotas, and licensing before you integrate.
Free commodity price API: the practical answer
A “free” API may mean a permanent low-volume tier, a trial, delayed quotes, daily observations, or an open public dataset. Choose by the job you need to complete, not by the word free.
- For a dashboard, confirm symbol coverage, update cadence, currency, unit, and timestamp.
- For research, confirm historical depth, missing-value policy, revisions, and download limits.
- For production, confirm authentication, rate limits, commercial use, attribution, and redistribution terms.
Know which commodity price the API returns
A commodity name is not a complete instrument identifier. “Gold,” “oil,” or “wheat” may point to a physical benchmark, an exchange futures contract, a daily settlement, a vendor assessment, or a composite index. Two correct APIs can therefore return different numbers at the same time.
| Price type | What it represents | Required context | Typical use |
|---|---|---|---|
| Physical spot or benchmark | A current cash-market reference for a specified grade and location. | Grade, location, delivery terms, currency, unit and publisher. | Procurement, inflation and physical-market analysis. |
| Futures trade or quote | A price for one exchange contract and delivery month. | Exchange, contract code, month, year, timestamp and session. | Hedging, curve analysis and contract-level research. |
| Official settlement | An exchange-defined end-of-day value used for marking positions. | Settlement date, contract, exchange methodology and correction status. | Daily valuation, risk and accounting workflows. |
| Assessed price | A publisher’s methodology-based estimate for a market that may trade sparsely. | Publisher, methodology, assessment window, grade and geography. | Physical contracts and specialized market reporting. |
| Continuous futures series | A synthetic history that rolls from one contract to another. | Roll rule, adjustment method, source contracts and roll dates. | Charts and research—not a directly tradable instrument. |
Do not normalize away the meaning. Convert units and field names only after storing the raw contract or benchmark identifier, source, price type and timestamp. A single column named commodity_price cannot safely mix spot, settlement and continuous futures values.
What commodity market data should the API cover?
Metals and precious metals prices
Gold, silver, copper, aluminum, platinum, and palladium may be spot benchmarks, exchange futures, or vendor assessments. Record which one the endpoint returns.
Energy and oil price data
WTI, Brent, natural gas, heating oil, and power data differ by venue, contract, region, delivery period, and settlement method.
Agricultural commodity prices
Wheat, corn, soybeans, coffee, sugar, and cotton often require contract month, exchange, grade, location, and unit context.
Official and public commodity data sources
Public sources are strongest when they publish the underlying statistic or benchmark directly. They are excellent for energy statistics, macro research and monthly commodity series, but they are not substitutes for licensed exchange-grade live feeds.
| Source | Useful coverage | Access pattern | Important limitation |
|---|---|---|---|
| U.S. EIA Open Data | Petroleum, natural gas, coal and electricity prices, supply, stocks and flows. | API v2, query browser and bulk files. | Dataset routes, facets, units and frequencies differ; an API key is required for API calls. |
| FRED | Economic commodity series collected from government and other publishers. | Series pages, downloads and a documented API. | Units, revision behavior and rights are series-specific; inspect the source notes. |
| World Bank Pink Sheet | Monthly and annual international commodity price benchmarks across energy, metals, agriculture and fertilizers. | Published reports and historical spreadsheet files. | Designed for macro and long-run analysis, not intraday trading. |
| Exchanges and contract specifications | Contract identifiers, sizes, grades, delivery locations, months and official settlement context. | Product pages, specifications and licensed data products. | Real-time quotes, depth and redistribution commonly require separate entitlements. |
For a broad research database, combine a public monthly or daily source with contract metadata. For a trading interface, obtain the correct market-data entitlement rather than relabeling a delayed or derived series as real time.
How to compare free commodity data APIs
| Check | Ask | Why it matters |
|---|---|---|
| Price type | Spot, futures, settlement, index, or assessed price? | Similar labels can represent different markets. |
| Freshness | Real-time, delayed, end-of-day, or periodically updated? | “Latest” does not prove real-time delivery. |
| History | Start date, frequency, revisions, and continuous series? | Backtests need reproducible observations. |
| Units | USD per barrel, ounce, tonne, bushel, or index points? | Wrong unit conversions silently corrupt results. |
| Free tier | Requests, symbols, retention, trial expiry, and attribution? | Free access may not support production. |
Normalize commodity prices without losing contract meaning
A clean table should make unlike observations impossible to confuse. Keep the source’s identifier beside your internal symbol, and model benchmark, contract month, price type, currency, unit and timestamps as separate fields. Convert values only after the raw response has been saved.
| Field | Store | Validation rule |
|---|---|---|
source_symbol | The provider’s exact series or contract code. | Never infer it from a display name. |
benchmark / contract_month | Physical benchmark or exchange contract and delivery month. | Required for futures and location-specific prices. |
price_type | Spot, trade, bid, ask, settlement, assessment or continuous series. | Do not silently replace one type with another. |
price / currency / unit | Numeric value plus its quote currency and physical unit. | Record conversion factors and rounding explicitly. |
observation_time / release_time | When the market value applies and when it became available. | Store timezone and distinguish event time from ingestion time. |
revision / source | Correction status, retrieval time and provenance URL. | Retain prior versions when reproducibility matters. |
Continuous futures need their own lineage. Save the underlying contracts, roll dates, roll trigger and adjustment method. Back-adjusted history can be useful for return research, but its old price levels are synthetic.
How to use a commodity price API in Python
1. Define the commodity and price meaning
Write down the commodity, benchmark or contract, venue, currency, unit, timezone, and required frequency before selecting an endpoint.
2. Test one free JSON request
Start with the provider’s official documentation. Keep the API key outside source code, set a timeout, and capture quota and freshness metadata.
3. Normalize price, unit, and timestamp
Store the raw symbol and source. Convert units explicitly, reject missing timestamps, flag stale values, and preserve revision dates for historical observations.
4. Add rate-limit-safe retries
Use bounded exponential backoff for transient errors, respect 429 responses, cache slow-changing series, and avoid spending a small free quota on unnecessary polling.
Quality checks before a commodity API reaches production
A successful HTTP response proves transport, not data quality. Run checks at ingestion and again after normalization. Set thresholds by dataset frequency: a monthly World Bank series and an intraday futures quote should not share one freshness rule.
Freshness and completeness
Compare the latest observation with the provider’s schedule, flag missing intervals, and distinguish a closed market from a failed feed.
Units and economic bounds
Reject unknown currencies or units, test conversions, and investigate implausible jumps without assuming every negative or extreme value is invalid.
Contract continuity
Detect symbol changes, expiries and roll gaps. Do not fill a missing front contract with another month unless the substitution is explicit.
Revisions and reconciliation
Keep retrieval versions for revised public series and periodically reconcile sampled values with the publisher’s own page or file.
License and redistribution
Record attribution, display, storage and redistribution rules with the dataset. Technical access is not automatically permission to republish.
For backtests: query information as it was available on each decision date whenever revisions, contract rolls or delayed publication matter. Using today’s corrected series across the entire history can introduce look-ahead bias.
Use QVeris to find commodity price API capabilities
QVeris helps developers and agents discover callable data capabilities and inspect inputs before integration. It does not make licensed exchange data free or guarantee that a provider is suitable for trading.
- Search the QVeris Tool Finder for commodity and financial-data capabilities.
- Inspect symbols, parameters, authentication, output schema, units, and timestamps before an agent calls a provider.
- Keep licensing, accuracy, latency, and suitability checks in your approval process.
FAQ
Is there a free API for commodity prices?
Yes, but “free” varies: public datasets, delayed feeds, low-volume tiers, and trials have different coverage and usage rights.
Can I get real-time commodity prices through a free API?
Sometimes for selected products or limited quotas. Verify the timestamp, delay policy, exchange entitlement, and redistribution terms.
Which commodities can a price API cover?
Common groups include precious and industrial metals, energy, and agriculture. Coverage does not guarantee the same price type or frequency.
Can I get historical commodity prices in JSON?
Many APIs return JSON history, but depth, frequency, revisions, continuous-series construction, and free limits vary.
Can a free commodity API be used for trading?
Only after validating license, latency, corrections, reliability, and suitability. A free tier alone is not evidence of execution-grade data.
