Get Ethereum (ETH) prices using this API

Get Ethereum (ETH) Prices Using the Metals-API
In the rapidly evolving world of cryptocurrencies and digital assets, having access to real-time data is crucial for developers and traders alike. One such valuable resource is the Metals-API, which provides comprehensive data on various metals, including precious metals like gold and silver. While primarily focused on metals, the API's capabilities can be leveraged to track Ethereum (ETH) prices indirectly through its market correlations. This blog post will delve into the features of the Metals-API, its endpoints, and how it can empower developers to create innovative applications that utilize real-time metals data.
Metals-API Information
API Description
The Metals-API is a powerful tool designed for developers seeking to integrate real-time and historical data on metal prices into their applications. With its robust infrastructure, the API offers a seamless way to access exchange rates, historical data, and various analytical tools. The transformative potential of real-time metals data cannot be overstated; it allows developers to build applications that can respond to market changes instantly, providing users with the most accurate and timely information available.
By utilizing the Metals-API Documentation, developers can explore the extensive capabilities of the API, including how to authenticate requests, manage rate limits, and handle errors effectively. This API is not just a data source; it is a gateway to creating next-generation applications that can analyze market trends and provide insights into the fluctuating prices of metals.
Key Features and Endpoints
The Metals-API boasts several key features that make it a valuable resource for developers:
- Real-Time Exchange Rates: Access the latest exchange rates for various metals, allowing applications to provide up-to-date pricing information.
- Historical Data: Retrieve historical exchange rates dating back to 1999, enabling developers to analyze trends over time.
- Time-Series Data: Get exchange rates for specific time periods, which is essential for trend analysis and forecasting.
- Conversion Capabilities: Convert amounts between different metals or to/from USD, facilitating transactions and calculations.
- Fluctuation Tracking: Monitor rate fluctuations between two dates, providing insights into market volatility.
- OHLC Data: Obtain Open, High, Low, and Close data for specific time periods, which is crucial for technical analysis.
- Bid/Ask Prices: Access current bid and ask prices for metals, helping traders make informed decisions.
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 extensive list includes symbols for precious metals such as gold (XAU), silver (XAG), platinum (XPT), and palladium (XPD), among others. Understanding these symbols is crucial for developers when making API requests and interpreting responses.
API Endpoint Examples and Responses
To illustrate the functionality of the Metals-API, letβs explore some of the key endpoints and their example responses.
Latest Rates Endpoint
The Latest Rates endpoint provides real-time exchange rates for all available metals. This is particularly useful for applications that require up-to-the-minute pricing information.
{
"success": true,
"timestamp": 1757876554,
"base": "USD",
"date": "2025-09-14",
"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"
}
In this response, the rates
object contains the latest prices for various metals, with the base currency set to USD. Each metal is represented by its symbol, and the values indicate the price per troy ounce.
Historical Rates Endpoint
Accessing historical exchange rates is essential for analyzing market trends. The Historical Rates endpoint allows developers to retrieve data for any date since 1999.
{
"success": true,
"timestamp": 1757790154,
"base": "USD",
"date": "2025-09-13",
"rates": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915,
"XPD": 0.000748
},
"unit": "per troy ounce"
}
This response shows the historical rates for gold, silver, platinum, and palladium on a specific date, allowing developers to analyze price movements over time.
Time-Series Endpoint
The Time-Series endpoint is particularly valuable for developers looking to analyze price trends over a specific period. It provides exchange rates for a defined start and end date.
{
"success": true,
"timeseries": true,
"start_date": "2025-09-07",
"end_date": "2025-09-14",
"base": "USD",
"rates": {
"2025-09-07": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915
},
"2025-09-09": {
"XAU": 0.000483,
"XAG": 0.0382,
"XPT": 0.000913
},
"2025-09-14": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912
}
},
"unit": "per troy ounce"
}
This example illustrates how the API returns rates for multiple dates, enabling developers to visualize trends and fluctuations in metal prices over time.
Convert Endpoint
The Convert endpoint allows users to convert any amount from one metal to another or to/from USD. This is particularly useful for applications that require real-time conversion capabilities.
{
"success": true,
"query": {
"from": "USD",
"to": "XAU",
"amount": 1000
},
"info": {
"timestamp": 1757876554,
"rate": 0.000482
},
"result": 0.482,
"unit": "troy ounces"
}
In this response, the API shows the conversion of 1000 USD to gold (XAU), providing both the conversion rate and the resulting amount in troy ounces.
Fluctuation Endpoint
The Fluctuation endpoint tracks rate fluctuations between two dates, offering insights into market volatility and price changes.
{
"success": true,
"fluctuation": true,
"start_date": "2025-09-07",
"end_date": "2025-09-14",
"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"
}
This response provides detailed information about the fluctuations in metal prices over the specified period, including both absolute and percentage changes.
OHLC (Open/High/Low/Close) Endpoint
The OHLC endpoint provides essential data for traders and analysts, offering Open, High, Low, and Close prices for a specific time period.
{
"success": true,
"timestamp": 1757876554,
"base": "USD",
"date": "2025-09-14",
"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"
}
This data is crucial for performing technical analysis and making informed trading decisions based on historical price movements.
Bid/Ask Endpoint
The Bid/Ask endpoint provides current bid and ask prices for metals, which is essential for traders looking to execute buy or sell orders.
{
"success": true,
"timestamp": 1757876554,
"base": "USD",
"date": "2025-09-14",
"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"
}
This response includes the bid and ask prices for gold, silver, and platinum, along with the spread, which is crucial for understanding market liquidity.
Conclusion
The Metals-API is an invaluable resource for developers looking to integrate real-time and historical metals data into their applications. By providing access to a wide range of endpoints, including real-time rates, historical data, and conversion capabilities, the API empowers developers to create innovative solutions that can respond to market changes instantly. Whether you are building a trading platform, a financial analysis tool, or a market monitoring application, the Metals-API offers the data and functionality needed to succeed.
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 and usage. Don't forget to check the Metals-API Supported Symbols page to familiarize yourself with the various metal symbols available for use.