Skip to main content
Defined in EIP-695
Returns the currently configured chain ID, a value used in replay-protected transaction signing as introduced by EIP-155.

Parameters

This method does not accept any parameters.

Returns

string
A hexadecimal string representing the chain ID.

Error Handling

Common chain IDs: Ethereum Mainnet (0x1), Base Mainnet (0x2105), Base Sepolia (0x14a34).