Retrieve Gold Jul 2026 (GCN26) Historical Prices effortlessly with this API

Retrieve Gold Jul 2026 (GCN26) Historical Prices Effortlessly with this API
In the ever-evolving landscape of financial markets, the demand for accurate and timely data has never been more critical. For those interested in precious metals, particularly gold, having access to historical prices is essential for making informed investment decisions. The Metals-API provides a robust solution for developers looking to retrieve historical prices of gold and other metals effortlessly. This blog post will delve into the capabilities of the Metals-API, focusing on how to access historical prices for gold (XAU) and explore the innovative features that make this API a game-changer in the world of precious metals trading.
About Gold (XAU)
Gold has long been considered a safe haven asset, a hedge against inflation, and a store of value. As the world transitions into a more digital economy, the integration of technology in trading precious metals is becoming increasingly important. The digital transformation in precious metals trading is not just about buying and selling; it encompasses data analytics, market insights, and innovative price discovery mechanisms.
With the rise of digital asset solutions, investors and traders can now leverage advanced data analytics to gain insights into market trends and price movements. The Metals-API plays a pivotal role in this transformation by providing real-time and historical data that can be utilized for comprehensive market analysis. By integrating this API into trading platforms, developers can create applications that offer users a seamless experience in tracking gold prices and making informed decisions.
API Description
The Metals-API is designed to empower developers with the tools necessary to build next-generation applications focused on precious metals. This API offers a wide range of functionalities, including real-time exchange rates, historical data retrieval, and various endpoints tailored to meet the needs of developers and traders alike.
One of the standout features of the Metals-API is its ability to deliver real-time data updated at intervals based on the user's subscription plan. This means that whether you need data every minute or every hour, the API can accommodate your requirements. Additionally, the API supports a variety of endpoints that allow users to access specific data points, such as bid and ask prices, conversion rates, and historical trends.
For developers looking to dive deeper into the API's capabilities, the Metals-API Documentation provides comprehensive guidance on how to implement these features effectively.
Key Features and Endpoints
The Metals-API offers a plethora of endpoints that cater to various needs in the precious metals market. Here are some of the key features:
- Latest Rates Endpoint: This endpoint provides real-time exchange rate data for gold and other metals. Depending on your subscription plan, you can receive updates every 60 minutes, every 10 minutes, or even more frequently.
- Historical Rates Endpoint: Access historical rates for gold dating back to 2019. By appending a specific date to your query, you can retrieve the price of gold on that particular day, allowing for detailed analysis of price movements over time.
- Bid And Ask Endpoint: This powerful feature enables users to retrieve real-time bid and ask prices for gold, providing insights into market liquidity and pricing dynamics.
- Convert Endpoint: The Metals-API includes a currency conversion endpoint, allowing users to convert amounts from one metal to another or to/from USD, facilitating easy transactions and calculations.
- Time-Series Endpoint: This endpoint allows users to query daily historical rates between two dates of their choice, making it easier to analyze trends over specific periods.
- Fluctuation Endpoint: Track how gold prices fluctuate on a day-to-day basis. This endpoint provides valuable insights into market volatility and price trends.
- Carat Endpoint: Retrieve information about gold rates by carat, which is particularly useful for jewelers and those in the jewelry industry.
- Lowest/Highest Price Endpoint: Query the API to get the lowest and highest prices for gold over a specified period, helping traders identify market extremes.
- Open/High/Low/Close (OHLC) Price Endpoint: This endpoint provides the open, high, low, and close prices for gold, essential for technical analysis and trading strategies.
- Historical LME Endpoint: Access historical rates for LME symbols dating back to 2008, allowing for comprehensive analysis of market trends.
- API Key: Your unique API key is essential for accessing the Metals-API. It must be included in the API base URL's access_key parameter.
- API Response: The API delivers exchange rates relative to USD by default, ensuring consistency in data interpretation.
- Available Endpoints: The Metals-API offers 14 different endpoints, each providing unique functionalities tailored to various user needs.
- Supported Symbols Endpoint: This endpoint returns all available currencies and metals, ensuring users can access the latest symbols and their specifications.
- Gold Price India Endpoint: Retrieve the latest gold price in India using this dedicated endpoint, catering to regional market needs.
- News Endpoint: Stay updated with the latest news articles related to various metals, providing context and insights into market movements.
List of Symbols
The Metals-API provides access to a comprehensive range of metal symbols. For a complete list of all supported symbols and their specifications, refer to the Metals-API Supported Symbols page. This resource is invaluable for developers looking to integrate specific metals into their applications.
API Endpoint Examples and Responses
Understanding the API's response structure is crucial for effective implementation. Below are examples of various endpoints and their corresponding JSON responses:
Latest Rates Endpoint
Get real-time exchange rates for all available metals.
{
"success": true,
"timestamp": 1759100433,
"base": "USD",
"date": "2025-09-28",
"rates": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912,
"XPD": 0.000744,
"XCU": 0.294118,
"XAL": 0.434783,
"XNI": 0.142857,
"XZN": 0.344828
},
"unit": "per troy ounce"
}
Historical Rates Endpoint
Access historical exchange rates for any date since 1999.
{
"success": true,
"timestamp": 1759014033,
"base": "USD",
"date": "2025-09-27",
"rates": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915,
"XPD": 0.000748
},
"unit": "per troy ounce"
}
Time-series Endpoint
Get exchange rates for a specific time period.
{
"success": true,
"timeseries": true,
"start_date": "2025-09-21",
"end_date": "2025-09-28",
"base": "USD",
"rates": {
"2025-09-21": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915
},
"2025-09-23": {
"XAU": 0.000483,
"XAG": 0.0382,
"XPT": 0.000913
},
"2025-09-28": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912
}
},
"unit": "per troy ounce"
}
Convert Endpoint
Convert any amount from one metal to another or to/from USD.
{
"success": true,
"query": {
"from": "USD",
"to": "XAU",
"amount": 1000
},
"info": {
"timestamp": 1759100433,
"rate": 0.000482
},
"result": 0.482,
"unit": "troy ounces"
}
Fluctuation Endpoint
Track rate fluctuations between two dates.
{
"success": true,
"fluctuation": true,
"start_date": "2025-09-21",
"end_date": "2025-09-28",
"base": "USD",
"rates": {
"XAU": {
"start_rate": 0.000485,
"end_rate": 0.000482,
"change": -3.0e-6,
"change_pct": -0.62
},
"XAG": {
"start_rate": 0.03825,
"end_rate": 0.03815,
"change": -0.0001,
"change_pct": -0.26
},
"XPT": {
"start_rate": 0.000915,
"end_rate": 0.000912,
"change": -3.0e-6,
"change_pct": -0.33
}
},
"unit": "per troy ounce"
}
OHLC (Open/High/Low/Close) Endpoint
Get OHLC data for a specific time period.
{
"success": true,
"timestamp": 1759100433,
"base": "USD",
"date": "2025-09-28",
"rates": {
"XAU": {
"open": 0.000485,
"high": 0.000487,
"low": 0.000481,
"close": 0.000482
},
"XAG": {
"open": 0.03825,
"high": 0.0383,
"low": 0.0381,
"close": 0.03815
},
"XPT": {
"open": 0.000915,
"high": 0.000918,
"low": 0.00091,
"close": 0.000912
}
},
"unit": "per troy ounce"
}
Bid/Ask Endpoint
Get current bid and ask prices for metals.
{
"success": true,
"timestamp": 1759100433,
"base": "USD",
"date": "2025-09-28",
"rates": {
"XAU": {
"bid": 0.000481,
"ask": 0.000483,
"spread": 2.0e-6
},
"XAG": {
"bid": 0.0381,
"ask": 0.0382,
"spread": 0.0001
},
"XPT": {
"bid": 0.000911,
"ask": 0.000913,
"spread": 2.0e-6
}
},
"unit": "per troy ounce"
}
Conclusion
The Metals-API is a powerful tool for developers and traders interested in precious metals, particularly gold. With its extensive range of endpoints and real-time data capabilities, it provides the necessary resources to make informed trading decisions. By leveraging the API's features, developers can create innovative applications that enhance the trading experience and provide valuable insights into market trends.
As the digital transformation of the financial markets continues, APIs like Metals-API will play a crucial role in shaping the future of trading. For those looking to integrate historical price data into their applications, the Metals-API offers a comprehensive solution that is both user-friendly and technically robust. To get started, explore the Metals-API Documentation and discover how you can harness the power of real-time metals data.