Get Gold UAE 24 k (XAUUAE24) - Per Gram Historical Prices for Currency Conversion using this API
Get Gold UAE 24 k (XAUUAE24) - Per Gram Historical Prices for Currency Conversion using this API
In the rapidly evolving world of finance, the demand for accurate and real-time data has never been higher. For developers and businesses dealing with precious metals, having access to historical prices and current rates is crucial. This is where the Metals-API comes into play, offering a robust solution for retrieving gold prices, specifically for Gold (XAU), including its historical data for currency conversion. This blog post will delve into the intricacies of the Metals-API, focusing on how to obtain historical prices for Gold (XAU) and the innovative features that make this API a powerful tool for developers.
About Gold (XAU)
Gold, represented by the symbol XAU, is one of the most sought-after precious metals in the world. Its value is not only a reflection of market demand but also a safe haven for investors during economic uncertainty. The digital transformation in precious metals trading has opened new avenues for data analytics and market insights. With the integration of technology in trading, developers can leverage real-time data to innovate price discovery processes and create digital asset solutions.
As the market for precious metals continues to evolve, understanding the historical prices of gold becomes essential for making informed decisions. The Metals-API provides a comprehensive suite of tools that allow developers to access this data seamlessly. By utilizing the API, businesses can integrate gold pricing data into their applications, enhancing their offerings and providing users with valuable insights.
API Description
The Metals-API is designed to empower developers with real-time and historical data on precious metals. With its innovative capabilities, the API allows for the creation of next-generation applications that can analyze market trends, track price fluctuations, and convert currencies with ease. The API is built with a focus on technological advancement, ensuring that users have access to the most accurate and up-to-date information available.
For developers looking to implement the Metals-API, the Metals-API Documentation provides comprehensive guidance on how to utilize its features effectively. The documentation covers everything from authentication to endpoint usage, ensuring that developers can integrate the API into their applications without hassle.
Key Features and Endpoints
The Metals-API boasts a variety of endpoints that cater to different needs, each offering unique functionalities that can be leveraged for various applications. Here are some of the key features:
- Latest Rates Endpoint: This endpoint provides real-time exchange rate data for precious metals, updated every 60 minutes, 10 minutes, or even more frequently depending on your subscription plan. This feature is crucial for applications that require up-to-the-minute pricing information.
- Historical Rates Endpoint: Access historical rates dating back to 2019. By appending a specific date to your query, you can retrieve the historical price of gold (XAU) and other metals, allowing for in-depth analysis and reporting.
- Bid And Ask Endpoint: This powerful feature enables users to retrieve real-time bid and ask prices for metals, providing insights into market liquidity and pricing strategies.
- Convert Endpoint: The conversion endpoint allows users to convert any amount from one currency to another, facilitating seamless transactions and financial analysis.
- Time-Series Endpoint: Query the API for daily historical rates between two dates of your choice. This feature is particularly useful for trend analysis and forecasting.
- Fluctuation Endpoint: Track how currencies fluctuate on a day-to-day basis, providing insights into market volatility and price stability.
- Carat Endpoint: Retrieve information about gold rates by carat, which is essential for jewelers and consumers interested in specific gold qualities.
- Lowest/Highest Price Endpoint: This endpoint allows users to query the API for the lowest and highest prices of gold over a specified period, aiding in investment decisions.
- Open/High/Low/Close (OHLC) Price Endpoint: Get detailed OHLC data for a specific time period, which is vital for traders looking to analyze market movements.
- Historical LME Endpoint: Access historical rates for LME symbols dating back to 2008, providing a comprehensive view of market trends.
- API Key: Each user is assigned a unique API key that must be included in the API requests to authenticate and authorize access.
- API Response: The API delivers exchange rates relative to USD by default, ensuring that users have a consistent reference point for their data.
- Available Endpoints: The Metals-API offers 14 different endpoints, each tailored to provide specific functionalities for users.
- Supported Symbols Endpoint: This endpoint returns all available currencies, allowing users to stay updated on the latest symbols supported by the API.
- News Endpoint: Retrieve the latest news articles related to various metals, keeping users informed about market developments.
List of Symbols
The Metals-API provides access to a comprehensive range of metal symbols, including but not limited to:
- XAU - Gold
- XAG - Silver
- XPT - Platinum
- XPD - Palladium
For a complete list of all supported symbols and their specifications, refer to the Metals-API Supported Symbols page.
API Endpoint Examples and Responses
Understanding how to interact with the Metals-API is crucial for effective implementation. Below are examples of various API endpoints and their corresponding JSON responses:
Latest Rates Endpoint
Get real-time exchange rates for all available metals.
{
"success": true,
"timestamp": 1766278827,
"base": "USD",
"date": "2025-12-21",
"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": 1766192427,
"base": "USD",
"date": "2025-12-20",
"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-12-14",
"end_date": "2025-12-21",
"base": "USD",
"rates": {
"2025-12-14": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915
},
"2025-12-16": {
"XAU": 0.000483,
"XAG": 0.0382,
"XPT": 0.000913
},
"2025-12-21": {
"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": 1766278827,
"rate": 0.000482
},
"result": 0.482,
"unit": "troy ounces"
}
Fluctuation Endpoint
Track rate fluctuations between two dates.
{
"success": true,
"fluctuation": true,
"start_date": "2025-12-14",
"end_date": "2025-12-21",
"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": 1766278827,
"base": "USD",
"date": "2025-12-21",
"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": 1766278827,
"base": "USD",
"date": "2025-12-21",
"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 looking to integrate precious metals data into their applications. With its extensive range of features, including real-time rates, historical data, and various endpoints for conversion and analysis, the API provides everything needed to make informed decisions in the precious metals market. By leveraging the capabilities of the Metals-API, developers can create innovative solutions that enhance user experience and provide valuable insights into market trends.
For more information on how to get started with the Metals-API, visit the Metals-API Website and explore the Metals-API Documentation for detailed guidance on implementation. Don't forget to check the Metals-API Supported Symbols page to familiarize yourself with the various metal symbols available for use.