dYdX trading bot setup (2026): keys, testnet, fees and limits

Order-book perps on dYdX's own Cosmos chain; validators run the order book and you hold your own keys. Here's how to run a trading bot or AI agent on it without handing it more power than it needs. Every fact links dYdX's own docs, checked Oct 30, 2026.

Watch out: Pin client package versions: its official npm and PyPI packages were compromised in January 2026.

Safety scoreSafety 68%
Bot keyPermissioned keys can block withdrawals source
TestnetYes source
Base fees (maker / taker)0.01% / 0.05% source
Rate limitsLong-lived orders: 2 per block and 20 per 100 blocks per account; short-term orders and cancels: 4,000 per 5 blocks. Indexer: 100 requests per 10 seconds per IP. source
Anyone can check an account's resultsYes, any address source
RestrictedUS, Canada and more source
Builder codesBuilder codes on any order, up to 1% of the fill, with no vote needed. source
ReferralsAffiliate program open after $10 of volume: up to 15% of referees' taker fees (capped per referral); vetted VIP affiliates more. source

Set up a bot on dYdX, step by step

  1. Make sure you're on the real site. Fake trading sites and bots copy every big exchange. Before you connect a wallet, use the official app at dydx.trade.
  2. Give the bot its own account. Put the bot in a separate sub-account or wallet with only the money it needs, so a bug or a leaked key can't reach the rest.
  3. Create the bot's key. Use a key that can trade but not send money out. Permissioned keys can be limited by action, market and sub-account, so a trading key can be barred from withdrawals and transfers. Keys can't cap order size or leverage. docs
  4. Run it on testnet first. Public testnet front end, indexer and faucet. docs
  5. Stay inside the rate limits. Long-lived orders: 2 per block and 20 per 100 blocks per account; short-term orders and cancels: 4,000 per 5 blocks. Indexer: 100 requests per 10 seconds per IP. docs
  6. Count the fees. Tier 1: 0.01% maker, 0.05% taker; governance can change fees, so check dydx.trade. docs
  7. Put limits outside the bot. A bot can't be trusted to police itself. TAS Guard adds order caps, phone approval and a kill switch in front of an AI agent, including Hyperliquid and EVM wallets.
  8. Let your results speak. The keyless indexer returns any address's positions, fills, transfers and historical PnL; MegaVault's results are public. docs That means a bot's record can be checked by anyone. Get your agent verified.

AI agent tools

No official MCP server or agent kit; community only. source

Code and audits

Open-source chain, indexer and clients; audit reports are in the v4-chain repo. source

Incidents, last 12 months

FAQ

Can I run a trading bot on dYdX?

Yes. dYdX has an API for automated trading. Permissioned keys can be limited by action, market and sub-account, so a trading key can be barred from withdrawals and transfers. Keys can't cap order size or leverage.

Does dYdX have a testnet?

Public testnet front end, indexer and faucet.

Can a dYdX API key withdraw my funds?

Permissioned keys can be limited by action, market and sub-account, so a trading key can be barred from withdrawals and transfers. Keys can't cap order size or leverage.

Can US residents use dYdX?

No. dYdX's terms restrict: US and Canada plus sanctioned places, per the docs' compliance page.

What are dYdX's trading fees for bots?

Tier 1: 0.01% maker, 0.05% taker; governance can change fees, so check dydx.trade.

Compare

Other exchanges: Hyperliquid · Lighter · Aster · GMX · Paradex · Extended · Pacifica · edgeX

Facts from dYdX's docs, terms and GitHub, read Oct 30, 2026; news reports are marked. Fees and limits change: confirm on dYdX's site. No referral links. Not financial advice.

Get the weekly AI trading bot stats

Who won, who lost and who got drained: verified results for AI agents, vaults and apps, new incidents and claims we checked. One email a week, unsubscribe anytime.

No spam. Unsubscribe anytime. Privacy