Integration

Kraken

Trade Kraken with NautilusTrader

Stream Kraken Spot and Futures market data and execute orders through an adapter written in Rust, with REST and WebSocket access, Spot L3 market-by-order data, spot margin trading, and full order and position reconciliation.

Spot and derivatives exchange

Spot, perpetuals, and futures

Data and execution

Written in Rust 🦀

Founded in 2011, Kraken is one of the longest-running cryptocurrency exchanges, known for security, regulatory compliance, and deep-liquidity markets across Europe and globally. Kraken Pro spans spot trading with margin on selected pairs and Kraken Derivatives (Futures): USD-margined and inverse perpetual swaps alongside fixed-maturity and flex futures, all reached over REST and WebSocket.

NautilusTrader integrates with Kraken Pro through nautilus-kraken, a platform adapter written in Rust with Python bindings, providing both data and execution clients. It streams order books, quotes, trades, bars, and mark, index, and funding updates, and handles request signing and authentication in the Rust core rather than calling an external Kraken SDK. Order, fill, and position updates drive reconciliation across both Spot and Futures.

The adapter also wires up the venue-specific machinery that matters in production: Kraken's authenticated level3 channel delivers Spot market-by-order data with CRC32 checksum validation, spot margintrading validates leverage tiers before submission, and Spot orders route through Kraken's WebSocket v2 trade channel with an automatic REST fallback. Each client targets a single product type, Spot or Futures.

Products

Spot with margin, USD-margined and inverse perpetual swaps, and dated futures, each reached through a client configured for one product type.

Spot

Cash and margin pairs

Standard cryptocurrency pairs quoted in USD, EUR, USDT, and more, with leveraged margin available on selected pairs. Bitcoin is normalized from Kraken's XBT to BTC at load time.

USD, EUR, and USDT quoting

Margin on selected pairs

ISO 4217 symbols, XBT normalized to BTC

BTC/USD.KRAKEN

USD-margined perpetuals

Multi-collateral, PF_

Linear perpetual swaps margined and settled in USD, prefixed PF_. These multi-collateral contracts make up the bulk of Kraken's derivatives listings.

USD-settled linear swaps

Hundreds of listed contracts

Mark, index, and funding feeds

PF_XBTUSD.KRAKEN

Inverse perpetuals

Coin-settled, PI_

Perpetual swaps prefixed PI_, quoted in USD but margined and settled in the base coin, so a Bitcoin contract carries Bitcoin as collateral.

Quoted in USD, settled in coin

Bitcoin, Ether, Litecoin, and XRP

Perpetual funding

PI_XBTUSD.KRAKEN

Dated futures

Fixed maturity and flex

Fixed-maturity futures that date the symbol, listed as inverse (FI_) and flex (FF_) contracts on quarterly expiry cycles alongside the perpetual swaps.

Inverse (FI_) and flex (FF_) contracts

Fixed, dated expiries

Same adapter as the perpetuals

FI_XBTUSD_260925.KRAKEN

Markets

Crypto majors across more than 1,500 spot pairs and roughly 320 futures contracts, spanning USD-margined and inverse perpetuals and dated futures.

Spot · USD, EUR, and USDT quoted

BTC

Bitcoin

ETH

Ethereum

SOL

Solana

XRP

XRP

ADA

Cardano

DOT

Polkadot

LINK

Chainlink

AVAX

Avalanche

ATOM

Cosmos

LTC

Litecoin

DOGE

Dogecoin

UNI

Uniswap

AAVE

Aave

ALGO

Algorand

TRX

TRON

FIL

Filecoin

+ More

Spot pairs quote in USD, EUR, USDT, and more, e.g. BTC/USD and ETH/EUR. The adapter normalizes Kraken's XBT to BTC at load time, so Bitcoin trades as BTC/USD rather than XBT/USD.

USD-margined perpetuals · Multi-collateral, PF_

XBT

Bitcoin

ETH

Ethereum

SOL

Solana

XRP

XRP

ADA

Cardano

DOT

Polkadot

LINK

Chainlink

ATOM

Cosmos

BCH

Bitcoin Cash

LTC

Litecoin

UNI

Uniswap

FIL

Filecoin

+ More

USD-margined perpetual swaps carry the PF_ prefix, e.g. PF_XBTUSD (Bitcoin) and PF_ETHUSD(Ethereum). Futures keep Kraken's native XBT rather than BTC.

Inverse perpetuals · Coin-settled, PI_

XBT

Bitcoin

ETH

Ethereum

LTC

Litecoin

XRP

XRP

Inverse perpetual swaps carry the PI_ prefix and settle in the base coin: PI_XBTUSD, PI_ETHUSD, PI_LTCUSD, and PI_XRPUSD.

Dated futures · Fixed maturity and flex

XBT

Bitcoin

ETH

Ethereum

SOL

Solana

LTC

Litecoin

XRP

XRP

Fixed-maturity contracts add a date to the symbol, e.g. FI_XBTUSD_260925 (inverse, 25 Sep 2026) and FF_ETHUSD_260925 (flex). These expire on fixed dates rather than running perpetually.

These are a representative sample. Kraken lists more than 1,500 spot pairs and around 320 futures contracts, and adds new ones continuously; the adapter discovers the live instrument set at startup and maps each supported Kraken symbol to a NautilusTrader instrument.

Data feeds

Each Kraken feed maps to a native NautilusTrader data type across the Spot and Futures streams.

Data feed

NautilusTrader type

Notes

Order book (L2)

OrderBookDeltas

Snapshot then deltas over WebSocket; Spot and Futures L2 updates.

Order book (L3, market-by-order)

OrderBookDeltas

Spot per-order book over the authenticated level3 channel, with venue order IDs and CRC32 checksum validation.

Quotes

QuoteTick

Best bid and offer derived from the ticker channel on Spot and Futures.

Trades

TradeTick

Live public trades on Spot and Futures, with REST history.

Bars

Bar

Spot WebSocket OHLC from 1 minute to 15 days; Futures bars are historical over REST.

Mark price

MarkPriceUpdate

Mark price from the Futures ticker feed.

Index price

IndexPriceUpdate

Underlying index price from the Futures ticker feed.

Funding rate

FundingRateUpdate

Perpetual funding from the Futures ticker; the interval is unset because Kraken does not publish one.

Instruments

CurrencyPairTokenizedAssetCryptoPerpetual

Spot pairs, tokenized equities (xStocks), and futures contracts discovered at startup.

Status

InstrumentStatus

Trading-status transitions per instrument.

Order types

Kraken supports these Nautilus order types across Spot and Futures; the two trailing-stop variants are Spot only.

Type

Spot

Futures

Notes

MARKET

Immediate execution at the current market price.

LIMIT

Executed only at the specified price or better.

STOP_MARKET

Conditional trigger to a market order, evaluated at the venue.

STOP_LIMIT

Conditional trigger to a limit order, carrying both price and trigger price.

MARKET_IF_TOUCHED

Take-profit trigger to a market order.

LIMIT_IF_TOUCHED

Take-profit trigger to a limit order.

TRAILING_STOP_MARKET

Trailing stop with a trailing offset; Spot only.

TRAILING_STOP_LIMIT

Trailing stop that additionally carries a limit offset; Spot only.

Time in force

GTC and IOC are native on both markets. Good-till-date and fill-or-kill are Spot only.

Type

Spot

Futures

Notes

GTC

Good-till-canceled; the default for resting orders.

GTD

Good-till-date on Spot, requiring an expire time; no native Futures support.

IOC

Immediate-or-cancel; applies to limit-type orders.

FOK

Fill-or-kill on Spot limit orders only.

Data and execution clients

Data client

Public and authenticated REST and WebSocket streams

Feeds: order books at L2 and Spot L3, quotes, trades, bars, and mark, index, and funding updates.

Products: one client per product type, `SPOT` or `FUTURES`, selected by config; a single client does not span both markets.

Resilience: reconnecting WebSocket with snapshot-and-buffer book recovery, plus CRC32 checksum validation and resync on the Spot L3 channel.

Execution client

Signed orders over Spot WebSocket v2 with a REST fallback, and Futures REST

Orders: entry, in-place amend, conditional triggers, and trailing orders, with batch submit and batch cancel chunked to Kraken's limits.

Account: order, fill, and position updates drive reconciliation across Spot and Futures, including margin balances and open positions.

Margin: opt-in Spot margin with per-order leverage tiers validated against the venue before submission.

How the integration works

Adapter crate

nautilus-kraken, a Rust core with Python bindings.

Data client

KrakenDataClient streams instruments, books at L2 and Spot L3, quotes, trades, bars, and mark, index, and funding updates.

Execution client

KrakenExecutionClient handles signed orders, account queries, and reconciliation.

Signing

HMAC-SHA512-signed REST requests, handled in the Rust core, with a token for Spot WebSocket and a signed challenge for Futures WebSocket.

Product types

Spot (CurrencyPair, plus TokenizedAsset for xStocks) and Futures (CryptoPerpetual), one product type per client.

Environments

Live and demo, selected by KrakenEnvironment; demo is Futures only.

Authentication

API key and secret, separate for Spot and Futures.

Considerations

•

Public market data needs no credentials; execution needs an API key and secret, and the Spot L3 market-by-order channel is authenticated, so it needs Spot credentials too.

•

Each Kraken client is configured for a single product type, SPOT or FUTURES; one client does not span both markets, and Spot and Futures use separate credentials.

•

Spot normalizes Bitcoin to BTC (e.g. BTC/USD), whether XBT appears as the base or quote currency, while Futures keep Kraken's native XBT (e.g. PI_XBTUSD).

•

Instrument IDs use ISO 4217 symbols for Spot (BTC/USD.KRAKEN) and Kraken's prefixed symbols for Futures: PI_ inverse perpetual, PF_ USD-margined perpetual, and FI_ and FF_ dated contracts.

•

Kraken's tokenized equities (xStocks) load as Spot TokenizedAsset instruments in the equity asset class, fetched under Kraken's tokenized-asset class flag.

•

Private access is authenticated in the Rust core: REST requests are signed with HMAC-SHA512 over a nonce and body, Spot WebSocket sessions authenticate with a token from a signed REST call, and Futures WebSocket signs a server-issued challenge.

•

Spot orders route through Kraken's WebSocket v2 trade channel by default, falling back to REST; some order shapes, such as trailing stops and iceberg orders, always route via REST.

•

Spot margin trading is opt-in per execution client; requested leverage tiers are validated against the venue's advertised buy and sell tiers, and an invalid tier is denied before it reaches the venue.

•

Bars stream over WebSocket on Spot only, buffered and emitted one period late so only complete bars are published; internal aggregation from trades is recommended for lower latency.

•

Funding rate updates carry no interval because Kraken's ticker feed does not publish one.

•

Batch submit chunks at 15 orders on Spot and 10 on Futures, batch cancel auto-chunks at 50, and batch modify is Futures only.

•

Cancel-all ignores order side; on Spot it clears every symbol, while on Futures it requires an instrument and clears that symbol only.

•

Order lists, OCO, and bracket orders are not supported; stop and take-profit conditional orders are.

•

Only Kraken Futures offers a demo environment for paper trading; Kraken Spot has no demo or testnet.

•

Kraken's counter-based rate limit rewards longer reconciliation intervals; the guide recommends conservative open- and position-check settings, especially on the Starter tier.

Integration guide

Read the full integration guide

The guide covers installation, account setup, configuration, symbology, order handling, spot margin, rate limits, and worked examples for trading Kraken.

footer-logo

© 2026 Nautech Systems Pty Ltd. All rights reserved.

NautilusTraderâ„¢ is a product of Nautech Systems Pty Ltd (ABN 88 609 589 237). Nautech Systems provides algorithmic trading software only. We do not operate as a broker, dealer, or exchange, nor offer financial advisory services. Users are solely responsible for compliance with applicable laws and regulations. Subject to non-excludable consumer guarantees, we make no warranties and accept no liability for trading losses or regulatory violations arising from use of the software. Read full disclaimer.

We use essential cookies and, with your consent, optional analytics cookies, as described in our Privacy Policy. Manage your Cookie Preferences.