# Unichain RPC Endpoint: Chain ID 130, HTTPS and WebSocket

## Unichain RPC plans and rate limits

- **Free plan:** 20 responses per second, up to 100,000 responses a day.
- **Plans:** $49/mo, $299/mo, $999/mo with 25M, 150M, and 500M included responses. Overages billed at $5/$3/$2 per million responses respectively.
- **Paid rate limits:** 100 to 5,000 responses per second (bursts from 500 to 10,000), no daily limit.
- **Billing:** 1 response = 1 API credit on every shared plan, over HTTPS or WebSocket (WSS) where Unichain supports it.

Details: [Pricing](https://www.dwellir.com/docs/getting-started/pricing) · [Rate limits](https://www.dwellir.com/docs/getting-started/rate-limits) · [Authentication](https://www.dwellir.com/docs/getting-started/authentication) · [Archive nodes](https://www.dwellir.com/docs/getting-started/archive-nodes)

## Why Build on Unichain?

To get a Unichain mainnet endpoint, see [Unichain RPC endpoints](https://www.dwellir.com/networks/unichain).

Unichain is a fast, decentralized Superchain L2 built to be the home for DeFi and liquidity across chains. Developed by Uniswap on the OP Stack, Unichain addresses key challenges in the Ethereum ecosystem with innovative solutions for cost, speed, and MEV protection.

### **Ultra-Fast Execution**

- **1-Second Block Times** - Fast transaction confirmations
- **250ms Sub-blocks** - Coming soon for instant user experiences
- **200-250ms Finality** - Significantly faster than Ethereum's 12 seconds

### **Cost-Efficient DeFi**

- **95% Lower Costs** - Compared to Ethereum L1
- **MEV Protection** - Verifiable block building with TEE
- **No Failed Transaction Fees** - Trustless revert protection

### **Cross-Chain Native**

- **Superchain Interoperability** - Single-block cross-chain messaging
- **ERC-7683 Support** - Cross-Chain Intents standard
- **Unified Liquidity** - Seamless multi-chain DeFi

## Quick Start with Unichain

## Network Specifications

| Parameter  | Value     | Details      |
| ---------- | --------- | ------------ |
| Chain ID   | 130       | Mainnet      |
| Currency   | ETH       | Native Token |
| Block Time | 1s        | 250ms soon   |
| Finality   | 200-250ms | Ultra-fast   |

## Unique Features

### **MEV Protection**

Unichain employs a **Trusted Execution Environment (TEE)** for verifiable block building, ensuring:

- Transparent transaction ordering
- Protection against MEV extraction
- Fair and predictable execution

### **UNI Token Utility**

The UNI token powers Unichain's validation network:

- **Stake UNI** to become a validator
- **Earn 65%** of net chain revenue
- **Secure the network** through decentralized validation

### **Stage 1 Rollup**

Unichain launches as a Stage 1 rollup with:

- Permissionless fault proof system
- Independent transaction verification
- Enhanced security from day one

### **Native Uniswap Integration**

- **Uniswap v4 Hooks** - Native integration for advanced DeFi
- **Optimized for DEX** - Purpose-built for decentralized trading
- **Liquidity Hub** - Central point for cross-chain liquidity

## Available Methods

## Developer Resources

### Smart Contract Development

```solidity
// Deploy your DeFi protocols on Unichain
pragma solidity ^0.8.0;

contract MyDeFiProtocol {
    // Leverage Unichain's fast execution and MEV protection
    // Native support for Uniswap v4 hooks
}
```

### Web3 Integration

```javascript
// Connect to Unichain with Web3.js
const Web3 = require('web3');
const web3 = new Web3('https://api-unichain-mainnet.dwellir.com');

// Unichain Mainnet Chain ID: 130
const chainId = 130;

async function getBlockNumber() {
  const blockNumber = await web3.eth.getBlockNumber();
  console.log('Latest Unichain block:', blockNumber);
}
```

### Ethers.js Example

```javascript
// Using Ethers.js with Unichain
import { ethers } from 'ethers';

const provider = new ethers.JsonRpcProvider(
  'https://api-unichain-mainnet.dwellir.com'
);

// Check network
const network = await provider.getNetwork();
console.log('Connected to Unichain:', network.chainId === 130);
```

## Ecosystem & DApps

### **DeFi Protocols**

Leading DeFi applications already deployed on Unichain:

- **Uniswap** - Native DEX with v4 hooks
- **Morpho** - Lending protocol
- **Euler** - Permissionless lending
- **Lido** - Liquid staking
- **Renzo** - Liquid restaking

### **Bridge Solutions**

- **Native Superchain Bridge** - Direct bridging within Optimism ecosystem
- **Cross-Chain Intents** - ERC-7683 standard support
- **Unified Liquidity** - Seamless asset movement

### **Developer Tools**

- **Open Source** - MIT licensed codebase
- **OP Stack Compatible** - Familiar development environment
- **TEE Integration** - Advanced security features

## Network Information

### Mainnet (Chain ID: 130)

| Parameter    | Value                                                | Details |
| ------------ | ---------------------------------------------------- | ------- |
| RPC Endpoint | `https://api-unichain-mainnet.dwellir.com`           |         |
| WebSocket    | `wss://api-unichain-mainnet.dwellir.com`             |         |
| Explorer     | [Unichain Explorer](https://unichain.blockscout.com) |         |
| Status       | Live                                                 |         |

### Testnet (Chain ID: 1301)

| Parameter    | Value                                                                | Details |
| ------------ | -------------------------------------------------------------------- | ------- |
| Network      | Unichain Sepolia                                                     |         |
| RPC Endpoint | `https://api-unichain-sepolia.n.dwellir.com/YOUR_API_KEY`            |         |
| WebSocket    | `wss://api-unichain-sepolia.n.dwellir.com/YOUR_API_KEY`              |         |
| Explorer     | [Unichain Sepolia Explorer](https://unichain-sepolia.blockscout.com) |         |
| Faucet       | Available for testing                                                |         |

## API Methods

### Core Ethereum Methods

All standard Ethereum JSON-RPC methods are supported:

- Transaction Methods (`eth_sendTransaction`, `eth_getTransactionReceipt`)
- Block Methods (`eth_getBlockByNumber`, `eth_blockNumber`)
- Account Methods (`eth_getBalance`, `eth_getCode`)
- Event Methods (`eth_getLogs`, `eth_newFilter`)

### Unichain L2 Specific

Enhanced methods for L2 operations:

- `eth_estimateL1Fee` - Estimate L1 fee component
- `rollup_gasPrices` - Get current L2 gas prices
- `rollup_getInfo` - Get rollup configuration

### Debug & Trace Methods

Advanced debugging capabilities:

- `debug_traceTransaction` - Detailed transaction traces
- `debug_traceBlockByNumber` - Block-level debugging
- `debug_traceCall` - Simulate and trace calls

## Best Practices

### 1. **Leverage Sub-blocks**

Take advantage of Unichain's upcoming 250ms sub-blocks for instant UX:

```javascript
// Monitor sub-blocks for real-time updates
provider.on('block', (blockNumber) => {
  // React to new blocks in near real-time
});
```

### 2. **MEV Protection**

Build with confidence knowing transactions are protected:

```javascript
// Transactions are protected from sandwich attacks
// and other MEV extraction techniques
const tx = await contract.swap(tokenA, tokenB, amount);
```

### 3. **Cross-Chain Design**

Design for interoperability from the start:

```javascript
// Leverage native cross-chain messaging
const crossChainTx = await bridge.sendMessage(
  targetChain,
  message
);
```

## Migration Guide

### From Ethereum Mainnet

1. Update chain ID to 130
2. Point RPC to Unichain endpoint
3. Enjoy 95% cost reduction

### From Other L2s

1. Minimal code changes required
2. Standard Ethereum tooling works
3. Enhanced features available

## Resources & Support

### Developer Resources

- **Official Docs**: [Unichain documentation](https://docs.unichain.org)
- **GitHub**: Open source codebase (MIT license)
- **Explorer**: [Unichain Explorer](https://unichain.blockscout.com)

### Need Help?

- **Email**: <support@dwellir.com>
- **Documentation**: You're here!
- **Dashboard**: [dashboard.dwellir.com](https://dashboard.dwellir.com)

### Related Reading

- [Best Unichain RPC Providers for 2026](https://www.dwellir.com/blog/best-unichain-rpc-providers)

***

*Start building on Unichain with Dwellir's enterprise-grade RPC infrastructure. [Get your API key](https://dashboard.dwellir.com/register)*
