> ## Documentation Index
> Fetch the complete documentation index at: https://docs.whitebit.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Kline

> Subscribe to real-time candlestick (OHLCV) chart updates for a trading pair via WhiteBIT WebSocket.

Query or subscribe to candlestick (OHLCV) data for a market and interval. Each candle contains open, high, low, close, and volume values for the specified interval. The server pushes updates every 0.5 seconds while a candle is active, reflecting the latest trade activity. Use this channel to power real-time charting or detect price movements as they occur.

<Note>Connect to `wss://api.whitebit.com/ws` — see [WebSocket Overview](/websocket/overview) for protocol details and keepalive requirements.</Note>

## Rate limits

## Query candlesticks (one-time)

Fetch historical candlestick data for a time range.

**Request**

**Response**

Each record is a positional array in the same format as the subscription update.

## Interval constraints

The interval must meet specific alignment rules to ensure candles align with natural time boundaries.

<Accordion title="Less than 60 seconds">
  60 must be divisible by the interval.

  Valid: `1`, `2`, `3`, `4`, `5`, `6`, `10`, `12`, `15`, `20`, `30`

  Invalid: `7`, `11`, `13`, `17`
</Accordion>

<Accordion title="60 seconds to 1 hour (60–3599s)">
  Interval must be divisible by 60, and 3600 must be divisible by the interval.

  Valid: `60` (1m), `120` (2m), `180` (3m), `300` (5m), `900` (15m), `1800` (30m)

  Invalid: `420` (7m), `660` (11m)
</Accordion>

<Accordion title="1 hour to 1 day (3600–86399s)">
  Interval must be divisible by 3600, and 86400 must be divisible by the interval.

  Valid: `3600` (1h), `7200` (2h), `14400` (4h), `21600` (6h), `43200` (12h)

  Invalid: `18000` (5h), `25200` (7h)
</Accordion>

<Accordion title="1 day and above">
  Valid: `86400` (1d), `172800` (2d), `259200` (3d), `604800` (1w), `2592000` (1mo)
</Accordion>

<Note>
  The constraints above ensure candles align with natural time boundaries (minutes, hours, days) for consistent charting.
</Note>

## Subscribe to candlesticks

## Update frequency

The server pushes updates every **0.5 seconds** while the candle is active.

## Error codes

## Candle object

* [Kline](/api-reference/market-data/kline) — candlestick data via REST for historical queries.
