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

# Deposit to Hyperliquid

> Accept payments from any chain and deposit directly to a Hyperliquid account.

Daimo can bridge funds from any chain to a Hyperliquid (Hypercore) account in one session. It uses a [final-call adapter](/advanced/sessions#contract-calls-calldata) on HyperEVM that forwards USDC into Hypercore via Hyperliquid's `CoreDepositWallet`.

## Quick start

```typescript theme={null}
import { hyperEvmUSDC } from "@daimo/sdk/common";
import { encodeFunctionData } from "viem";

const HYPERCORE_DEPOSIT_ADAPTER = "0x3Df610B9168472EfC3CD37ed5005c0e78946c308";

const calldata = encodeFunctionData({
  abi: [
    {
      name: "deposit",
      type: "function",
      inputs: [
        { name: "recipient", type: "address" },
        { name: "destinationDex", type: "uint32" },
      ],
      outputs: [],
      stateMutability: "nonpayable",
    },
  ],
  functionName: "deposit",
  args: [
    "0xRecipientAddress", // Hypercore recipient
    0,                    // 0 = perps, 0xFFFFFFFF = spot
  ],
});

const res = await fetch("https://api.daimo.com/v1/sessions", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    Authorization: "Bearer YOUR_API_KEY",
  },
  body: JSON.stringify({
    destination: {
      type: "evm",
      address: HYPERCORE_DEPOSIT_ADAPTER,
      chainId: hyperEvmUSDC.chainId,
      tokenAddress: hyperEvmUSDC.token,
      amountUnits: "10",
      calldata,
    },
    display: { title: "Deposit to Hyperliquid", verb: "Deposit" }
  }),
});
```

## Destination DEX

The `destinationDex` parameter controls where funds land on Hypercore.

| DEX   | Value                       | Use case                         |
| ----- | --------------------------- | -------------------------------- |
| Perps | `0`                         | Perpetual futures trading margin |
| Spot  | `4294967295` (`0xFFFFFFFF`) | Spot trading balances            |

## New account fee

Hyperliquid deducts \$1 from the first deposit to a new account, so a \$10 deposit lands as \~\$9 on Hypercore. Factor this into your `amountUnits` if needed.

## Refund address

Always set `refundAddress` when using calldata. If the adapter call reverts, funds go to the refund address and the session status becomes `bounced`.
