AllTick
-
stock api stock market datafinancial data apiAPI Rate Limits API Integration

US Stock API Rate Limits Explained: Requests per Minute vs Daily Quotas

Learn how US Stock API rate limits, requests per minute, and daily quotas work. Discover how batch requests reduce API usage and how to avoid exceeding endpoint-specific limits.

AllTick5 min read

Your stock dashboard works fine with ten symbols. Then you expand the watchlist, add background data jobs, and suddenly some API requests start failing. You check daily usage, but it is nowhere near the expected quota.

The issue may not be your daily allowance. It could be the Stock API Rate Limits applied to requests within a shorter time window. Understanding requests per minute and daily quotas is essential when scaling a US Stock API integration.

Requests Per Minute vs Daily Quotas

Requests per minute (RPM) control how frequently your application can send HTTP requests. A daily quota controls the total number of requests allowed over a day.

AllTick publishes the following HTTP limits:

PlanRequests Per MinuteDaily Quota
Free101,000
Basic6086,400
Premium600864,000
Professional1,2001,728,000
All US Stocks1,2001,728,000

The All US Stocks plan covers approximately 11,000 US stock symbols. These limits are associated with the API token and apply across HTTP requests, while individual endpoints may have stricter frequency restrictions. See AllTick's HTTP interface limits.

How Many Requests Does Your Stock Dashboard Need?

Consider an application monitoring 120 US stocks and refreshing their latest prices every 30 seconds.

If it sends one request per symbol, the usage becomes:

  • 120 × 2 = 240 requests per minute.
  • 240 × 1,440 = 345,600 requests per day, assuming continuous 24-hour polling.

However, one request per symbol is not always necessary. AllTick's /trade-tick endpoint supports multiple product codes in a single request. For eligible paid plans, the documentation recommends requesting no more than 50 codes at a time because of GET URL length limits.

The same 120 symbols can therefore be divided into three batches: 50, 50, and 20.

With three requests every 30 seconds, usage falls to:

  • 6 requests per minute.
  • 8,640 requests per day under continuous polling.

That is 97.5% fewer HTTP requests than querying every symbol separately. The calculation counts HTTP calls, not individual stock symbols.

This is why batch retrieval should be considered before upgrading a plan simply to obtain a higher request quota.

Manage Global and Endpoint-Specific Limits

AllTick applies HTTP request restrictions by API token, not by IP address. If two servers use the same token, their requests share the same overall request budget.

There is another detail worth watching: individual endpoints can have stricter limits than the overall RPM allowance.

For example, the Premium plan supports up to 10 combined HTTP requests per second, but /batch-kline is limited to one request every two seconds.

For K-line applications, AllTick recommends retrieving historical candles through /kline, storing them locally, and using /batch-kline to refresh the latest two candles for multiple products. This avoids repeatedly requesting the same historical data.

A simple Python scheduler can enforce both the global request rate and the endpoint-specific interval:

text
import threading
import time

class TokenLimiter:
    def __init__(self, requests_per_second, endpoint_gaps=None):
        if requests_per_second <= 0:
            raise ValueError("Requests per second must be positive")

        self.global_interval = 1 / requests_per_second
        self.endpoint_gaps = endpoint_gaps or {}
        self.next_global = 0.0
        self.next_endpoint = {}
        self.lock = threading.Lock()

    def wait(self, endpoint):
        while True:
            with self.lock:
                now = time.monotonic()
                next_allowed = max(
                    self.next_global,
                    self.next_endpoint.get(endpoint, 0.0)
                )
                delay = next_allowed - now

                if delay <= 0:
                    self.next_global = now + self.global_interval
                    self.next_endpoint[endpoint] = (
                        now + self.endpoint_gaps.get(endpoint, 0.0)
                    )
                    return

            time.sleep(delay)

# Premium plan: 10 combined requests per second
limiter = TokenLimiter(
    requests_per_second=10,
    endpoint_gaps={"/batch-kline": 2.0}
)

# Call immediately before sending the HTTP request.
limiter.wait("/batch-kline")

The scheduler releases the lock before sleeping, allowing other threads to reserve their request slots. This example works within one Python process. Applications running across multiple servers need a centralized rate limiter or shared store such as Redis.

Daily request consumption should also be monitored separately. A scheduler that controls RPM does not automatically prevent the daily quota from being exhausted.

What Happens When You Exceed the Limit?

AllTick documents HTTP error codes 429 and 605 for request-frequency violations. When either appears, check the overall token usage and the specific endpoint's interval before retrying.

Avoid repeatedly sending the same request immediately after an error. Reduce unnecessary polling, add retry backoff, and reuse locally stored data where possible.

For applications that need continuous tick updates, WebSocket streaming may be a better fit than repeatedly polling REST endpoints. WebSocket connections and subscription limits are separate from HTTP request quotas.

When choosing a US Stock API, look beyond the requests-per-minute figure. Estimate daily consumption, check batch request capabilities, and account for every service sharing the same token.

Building a US stock market data application? Explore the AllTick US Stock API and review the applicable HTTP limits before planning your production request schedule.

Start streaming market data today

Generate a free API key in seconds and connect to every market from one endpoint.