> ## Documentation Index
> Fetch the complete documentation index at: https://seilabs-docs-evm-cookbook.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# @sei-js SDK

> TypeScript packages for building EVM applications on Sei

`@sei-js` is a set of TypeScript packages for building EVM applications on Sei. Use the packages for Sei-specific functionality, and use standard EVM libraries such as viem or ethers.js for everything else.

Sei is EVM-compatible, so you can also use Foundry, Hardhat, wagmi, and other Ethereum tooling. `@sei-js` adds precompile ABIs, chain definitions, wallet integration, network metadata, scaffolding, and an MCP server.

<Info>`@sei-js` is open source. Contribute at [github.com/sei-protocol/sei-js](https://github.com/sei-protocol/sei-js).</Info>

<Note>
  The current npm major versions are ESM-only: `@sei-js/precompiles@3`, `@sei-js/registry@2`, `@sei-js/create-sei@2`, `@sei-js/sei-global-wallet@2`, and `@sei-js/mcp-server@1`. Use `import`. `require()` does not resolve these packages. `@sei-js/precompiles` needs viem 2.55.16 or newer. The MCP server needs Node.js 20 or newer. `@sei-js/ledger` is not part of the current monorepo.
</Note>

## Why @sei-js?

* Typed ABIs and addresses for Sei precompiles
* Sei Mainnet and Sei Testnet chain definitions from viem, re-exported for convenience, plus a `seiLocal` definition for local nodes
* Packages that work with standard EVM libraries

## Packages

### [@sei-js/precompiles](/evm/precompiles)

Import precompile addresses and raw `*_PRECOMPILE_ABI` constants from the package root, `@sei-js/precompiles/precompiles`, or `@sei-js/precompiles/viem`. Import the ethers factories from `@sei-js/precompiles/ethers`.

The `sei` and `seiTestnet` chain definitions are part of viem, so import them from `viem/chains`. If you prefer a single import, the root and `viem` entrypoints re-export them. These entrypoints also export `seiLocal` for a local node.

```bash theme={null}
npm install @sei-js/precompiles@^3
```

### [@sei-js/create-sei](/evm/sei-js/create-sei)

Create a Next.js dApp with wallet integration, TypeScript, and Sei network configuration.

```bash theme={null}
npx @sei-js/create-sei app
```

### [@sei-js/sei-global-wallet](/evm/sei-global-wallet)

Add the EIP-6963-compatible Sei Global Wallet to a dApp.

```bash theme={null}
npm install @sei-js/sei-global-wallet
```

### [@sei-js/registry](/evm/sei-js/registry)

Use typed chain IDs, RPC endpoints, token metadata, and wallet information for Sei Mainnet and Sei Testnet.

```bash theme={null}
npm install @sei-js/registry
```

### [@sei-js/mcp-server](/ai/mcp-server)

Connect an MCP-compatible AI assistant to Sei for blockchain queries, contract interactions, and documentation search.

```bash theme={null}
npx @sei-js/mcp-server
```

## Deprecated packages

The five packages above are the entire current monorepo. Every other `@sei-js` package is deprecated on npm and no longer maintained. If your `package.json` includes one of these deprecated packages, migrate away from it.

| Deprecated package | What to use instead |
| - | - |
| `@sei-js/evm` | `@sei-js/precompiles` (the same library, renamed) |
| `@sei-js/ledger` | No replacement. For the EVM signing flow, see [Ledger with ethers](/evm/ledger-ethers) |
| `@sei-js/x402` | `@x402/core` and `@x402/evm`. See [x402 on Sei](/ai/x402) |
| `@sei-js/x402-fetch` | `@x402/fetch` and `@x402/evm` |
| `@sei-js/x402-axios` | `@x402/axios` and `@x402/evm` |
| `@sei-js/x402-express` | `@x402/express`, `@x402/core`, and `@x402/evm` |
| `@sei-js/x402-hono` | `@x402/hono`, `@x402/core`, and `@x402/evm` |
| `@sei-js/x402-next` | `@x402/next`, `@x402/core`, and `@x402/evm` |
| `@sei-js/core` | No replacement. Use viem or ethers.js for EVM access |
| `@sei-js/cosmjs` | No replacement |
| `@sei-js/cosmos` | No replacement |
| `@sei-js/proto` | No replacement |

The last four packages covered Cosmos SDK access, which is deprecated under [SIP-3](/learn/sip-03-migration). Build on the EVM instead.

## Quick start

Generate a new Sei dApp:

```bash theme={null}
npx @sei-js/create-sei app -n my-sei-app
cd my-sei-app
bun install
bun run dev
```

For the generated template and CLI options, see [Scaffold Sei](/evm/sei-js/create-sei).

## Examples

These end-to-end code examples use viem and ethers with Sei:

<CardGroup cols={2}>
  <Card title="viem quickstart" icon="bolt" href="/evm/evm-parity/examples/viem-quickstart">
    Read chain data, send transactions, and interact with contracts in a Node.js script or backend.
  </Card>

  <Card title="ethers v6 quickstart" icon="bolt" href="/evm/evm-parity/examples/ethers-quickstart">
    The same patterns with ethers v6, including the browser provider and event listening.
  </Card>

  <Card title="wagmi and React" icon="react" href="/evm/evm-parity/examples/wagmi-react">
    Connect wallets, read balances, and write contracts in a React dApp with wagmi hooks.
  </Card>

  <Card title="ERC-20 interaction" icon="coins" href="/evm/evm-parity/examples/erc20">
    Read metadata, check balances, transfer tokens, approve spenders, and query transfer history.
  </Card>

  <Card title="ERC-721 interaction" icon="image" href="/evm/evm-parity/examples/erc721">
    Check ownership, transfer NFTs, manage approvals, and watch transfer events.
  </Card>

  <Card title="ERC-1155 interaction" icon="grid-2" href="/evm/evm-parity/examples/erc1155">
    Batch balance queries, single and batch transfers, operator approvals, and event watching.
  </Card>

  <Card title="Multicall" icon="layer-group" href="/evm/evm-parity/examples/multicall">
    Batch multiple contract reads into a single RPC call with Multicall3 and viem, ethers, or wagmi.
  </Card>

  <Card title="Pointer contracts" icon="arrow-right-arrow-left" href="/evm/evm-parity/examples/pointer-contracts">
    Look up pointer addresses for existing CW20 and CW721 contracts, then interact with them through ERC interfaces.
  </Card>

  <Card title="Sei precompiles" icon="hexagon-nodes" href="/evm/evm-parity/examples/sei-precompiles">
    Native balances, staking, rewards, and governance voting from JavaScript.
  </Card>

  <Card title="Deploy and verify" icon="rocket" href="/evm/evm-parity/examples/deploy-verify">
    Deploy contracts with viem, ethers, Foundry, or Hardhat, and verify them on Seiscan through Sourcify.
  </Card>

  <Card title="Transaction lifecycle" icon="arrow-progress" href="/evm/evm-parity/examples/transaction-lifecycle">
    Send transactions, wait for receipts, and decode event logs.
  </Card>

  <Card title="Error handling" icon="triangle-exclamation" href="/evm/evm-parity/examples/error-handling">
    Decode reverts, handle wallet rejections, and retry transient RPC failures.
  </Card>
</CardGroup>

## Community and support

* [Discord](https://discord.gg/sei): Join the Sei developer community
* [GitHub Issues](https://github.com/sei-protocol/sei-js/issues): Report bugs and request features


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.