Get the RSI (Relative Strength Index) history of a futures trading pair on an exchange, with values from 0 to 100; the calculation period and the price used can be customized. Useful for identifying overbought and oversold conditions, or for building RSI alerts and backtests.
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Available on these API plans: Startup Standard Professional Enterprise
Response Data
data is an array; each element is the RSI of one interval, and time is the start time of the interval. RSI is calculated from the trading pair's price candles using Wilder's method, with values 0–100.
Fewer records are returned than the candles used in the calculationCalculating RSI requires a stretch of candles to accumulate first: the first
windowcandles are used only to start the calculation and are not returned. With the defaultwindow=9, requesting 60 1-hour candles returns 51 records, and the first record corresponds to the 10th candle. If you need N results, add the number of candles needed to start the calculation tolimit, or movestart_timeearlier by the corresponding number of intervals. If there are too few candles to start the calculation, the response contains no data.
The default period is 9, not 14If
windowis omitted, RSI is calculated over 9 periods. Many charting tools show RSI(14) by default; to compare with them, passwindow=14.
200 · application/json · See the response example in the right panel.
| Field | Type | Always Returned | Description |
|---|---|---|---|
code | string | Yes | Business status code; "0" means success |
msg | string | No | Result message; may be omitted on success |
data | array of object | No | Array of RSI values; each element is one interval. This field is not returned when there are not enough candles to start the calculation (the response contains only code) |
data[].time | integer (int64) | Yes | Interval start time, timestamp in milliseconds (UTC); the indicator value is calculated from candles up to and including this interval |
data[].rsi_value | number | Yes | RSI value, 0–100; calculated using Wilder's method |
API Plans
Only the API plans marked Yes in the table below can call this endpoint. For the price of each plan, see API Plans.
| API Plan | Access |
|---|---|
| Hobbyist | ❌ No |
| Startup | ✅ Yes |
| Standard | ✅ Yes |
| Professional | ✅ Yes |
| Enterprise | ✅ Yes |
The length of history you can query differs by API plan; if start_time is earlier than the range you can query, it is automatically changed to the earliest time available. For how far back each interval's history can be queried, see Intervals.
Use This Endpoint with AI
Pick a task and click Open in ChatGPT or Open in Claude: the AI reads this page first and then gives you the result. You can also click Copy and paste the full prompt into the AI tool you use.
This endpoint provides data through the REST API. Use the prompts above to have AI write the request code. For the tools available through MCP, see CoinGlass MCP.
Use Cases
| Scenario | Description |
|---|---|
| Identify Overbought and Oversold Conditions | An RSI above 70 is often regarded as overbought and below 30 as oversold; this can serve as a reference for short-term decisions. |
| Spot Divergences | If the price makes a new high but RSI does not, upward momentum may be weakening; if the price makes a new low while RSI rises, downward momentum may be weakening. |
| Indicator Alerts | Get the latest RSI on a schedule and push an alert when it crosses a threshold. |
| Strategy Backtesting | Use RSI history to backtest entry and exit rules on a single trading pair; when you need the current RSI of all coins, use Coin RSI List. |
Related Endpoints
| Endpoint | How It Differs |
|---|---|
| Coin RSI List | Current RSI and price change of all coins across multiple intervals; no parameters needed |
| Moving Average Convergence Divergence (MACD) | Another commonly used trend momentum indicator |
| TD Sequential Indicator | Uses consecutive counts to identify possible reversals |
| Pair Price OHLC History | Price candles for the same trading pair; can be aligned by time for comparison |
FAQ
Is the default window 14?
No, the default is 9. To get the common RSI(14), pass window=14.
Why are fewer records than limit returned, or even no data?
The first window candles are used only to start the calculation and are not returned. With the default window=9, requesting 60 candles returns 51 records. When there are too few candles to start the calculation (for instance, interval=1h with a time range of only 3 hours), the response contains only code and no data field.
Why doesn't it match the RSI on the exchange's chart?
Check each of the following: window (this endpoint defaults to 9, while many charts default to 14), interval, series_type (default close price), and whether the exchange and trading pair are the same. The last record corresponds to an interval that has not yet closed, so its value changes with the price.
Does a wrong series_type value return an error?
No. The endpoint recognizes only the four values open, high, low and close; any other value (including a typo) is calculated as close without an error, so check the spelling carefully.
Learn More: Relative Strength Index (RSI)
What Is RSI?
RSI (Relative Strength Index) compares the average gain with the average loss over a period, giving a result between 0 and 100: the closer to 100, the more recent gains dominate; the closer to 0, the more losses dominate. This endpoint calculates it using Wilder's method.
What Are the Overbought and Oversold Levels for RSI?
70 and 30 are commonly used: above 70 is regarded as overbought and below 30 as oversold. In strong trends, RSI may stay in the overbought or oversold zone for a long time, and some people use 80 and 20 instead. It is only a reference and does not mean the price will necessarily reverse.
How Do I View the RSI of All Coins at Once?
Use Coin RSI List, which returns the current RSI and price change of all coins across multiple intervals from 15 minutes to 1 week in one call.
