Skip to main content

General API Information

  • The base endpoint is: wss://ws-api.binance.com:443/ws-api/v3.
    • If you experience issues with the standard 443 port, alternative port 9443 is also available.
    • The base endpoint for testnet is: wss://testnet.binance.vision/ws-api/v3
  • A single connection to the API is only valid for 24 hours; expect to be disconnected after the 24-hour mark.
  • Websocket server will send a ping frame every 3 minutes.
    • If the websocket server does not receive a pong frame back from the connection within a 10 minute period, the connection will be disconnected.
    • When you receive a ping, you must send a pong with a copy of ping's payload as soon as possible.
    • Unsolicited pong frames are allowed, but will not prevent disconnection. It is recommended that the payload for these pong frames are empty.
  • Lists are returned in chronological order, unless noted otherwise.
  • All timestamps in the JSON responses are in milliseconds in UTC by default. To receive the information in microseconds, please add the parameter timeUnit=MICROSECOND or timeUnit=microsecond in the URL.
  • Timestamp parameters (e.g. startTime, endTime, timestamp) can be passed in milliseconds or microseconds.
  • All field names and values are case-sensitive, unless noted otherwise.