Account Structure
Both EVM derived (0x) and Sei bech32 derived addresses on Sei are derived from the same public key. Accounts are automatically linked once a transaction is broadcasted and the chain has their public key. This ensures that balances and transactions are reflected consistently across both address formats.
How It Works
Auto-linking:
- When an account broadcasts a transaction, the public key is recorded on-chain. This allows for the automatic linking of EVM and Sei addresses. Balances will be reflected in both address formats once linked.
Manual Association:
- If the chain does not yet have the public key, users can manually associate their accounts using the
sei_associate
function. This is a gasless function that requires at least 1 wei in their account to execute. More details can be found in the EVM RPC Endpoints documentation.
Key Points
- Different Accounts Before Linking: Until these accounts are linked, the chain treats the Sei address and EVM address as different accounts with different balances. This means that certain dApps may not be able to access your full balance until the accounts are linked.
- Public Key Requirement: The linking won’t happen until the chain has the public key. Using
sei_associate
, users can provide their public key to the chain without any gas fees, as long as they have at least 1 wei in their account.
Example
- Broadcast a Transaction: When you make any transaction from your EVM account, the public key is recorded, and the accounts get linked automatically.
- Manual Association Using
sei_associate
: If the accounts are not linked automatically, you can manually associate them with the following command as long as the account you are trying to associate has at least 1 wei in it:
seid tx evm associate-address [optional priv key hex] --rpc=<url> --from=<sender> [flags]