# Optimism

> Optimism Mainnet and Sepolia through RPC Gateway, with chain IDs, provider coverage, and the calls served without an Endpoint.

Canonical page: https://rpc.aurpay.net/docs/chains/optimism

Optimism is an EVM rollup in the Gateway catalog with ETH as its gas token. Both of its networks are reachable over EVM JSON-RPC through a Gateway Access Point.

## Networks and hosts

| Network | Chain ID | JSON-RPC Host |
|---|---:|---|
| Mainnet | 10 | `op-jsonrpc` |
| Sepolia | 11155420 | `op-sepolia-jsonrpc` |

Optimism Sepolia (11155420) and Base Sepolia (84532) are distinct networks with distinct Gateways, so confirm the chain ID before pointing a client at an Access Point.

## Provider coverage

| Provider | Mainnet | Sepolia | Generated URL form |
|---|:---:|:---:|---|
| [Alchemy](https://rpc.aurpay.net/docs/providers/alchemy.md) | Yes | Yes | `https://<network-subdomain>.g.alchemy.com/v2` |
| [QuickNode](https://rpc.aurpay.net/docs/providers/quicknode.md) | Yes | Yes | The URL QuickNode already issued for the Endpoint |
| [Chainstack](https://rpc.aurpay.net/docs/providers/chainstack.md) | Yes | Yes | The node's HTTPS endpoint |
| [dRPC](https://rpc.aurpay.net/docs/providers/drpc.md) | Yes | Yes | `https://lb.drpc.live/<network>/` |
| [Tenderly](https://rpc.aurpay.net/docs/providers/tenderly.md) | Yes | Yes | `https://<network-slug>.gateway.tenderly.co` |

Every one of these applies its credential as a path segment, so treat the effective Endpoint URL as a secret.

## Reads without an Endpoint

The shared cache answers `eth_blockNumber`, `eth_getBlockByNumber` with `["latest", false]` or an explicit hexadecimal height and `false`, and `debug_traceBlockByNumber` with the `callTracer` configuration. Other parameter variants and writes go to the Route. See [Endpoint-free RPC](https://rpc.aurpay.net/docs/endpoint-free-rpc.md) for the exact forms and cache behavior.

## Verify the network

```bash
curl '<optimism_access_point>' \
  -H 'Authorization: Bearer <app_api_key>' \
  -H 'Content-Type: application/json' \
  --data '{"jsonrpc":"2.0","id":1,"method":"eth_chainId","params":[]}'
```

Mainnet returns `0xa`; Sepolia returns `0xaa37dc`.

## Coverage boundary

One JSON-RPC 2.0 object per HTTP `POST`. Optimism-specific namespaces, trace output, and historical state depend on the upstream node's software and plan.

See [Routing and reliability](https://rpc.aurpay.net/docs/reliability.md) for the routing model and [JSON-RPC](https://rpc.aurpay.net/docs/json-rpc.md) for request format.
