Node RequirementsTo use the query and tx commands, your evmd node must either:
- Be fully synced with the network you’re interacting with, OR
- Be configured to use an external RPC endpoint in
~/.evmd/config/client.toml
Example client.toml configuration:# The network chain ID
chain-id = "myapp-1"
# The keyring's backend
keyring-backend = "os"
# CLI output format
output = "text"
# <host>:<port> to CometBFT RPC interface for this chain
node = "tcp://localhost:26657"
# Transaction broadcasting mode (sync|async)
broadcast-mode = "sync"
To use an external RPC, update the node field to point to a public or private RPC endpoint.
Global Flags
These flags are available for all commands:
| Flag | Description | Default |
|---|
-b, --broadcast-mode | Transaction broadcasting mode (sync|async) | sync |
--chain-id | Specify Chain ID for sending Tx | |
--fees | Fees to pay along with transaction (e.g., 10atest) | |
--from | Name or address of private key with which to sign | |
--gas-adjustment | Adjustment factor to multiply against the estimate returned by tx simulation | 1 |
--gas-prices | Gas prices to determine the transaction fee (e.g., 10atest) | |
--home | Directory for config and data | ~/.evmd |
--keyring-backend | Select keyring’s backend | os |
--log_format | The logging format (json|plain) | plain |
--log_level | The logging level | info |
--log_no_color | Disable colored logs | |
--node | <host>:<port> to CometBFT RPC interface | tcp://localhost:26657 |
--trace | Print out full stack trace on errors | |
Commands
Node Operations
Key Management
EVM Queries
ERC20 Queries
Feemarket Queries
Precisebank Queries
Cosmos SDK Queries
EVM Transactions
ERC20 Transactions
Cosmos SDK Transactions
Advanced Commands
Starting the Node
Node Initialization
evmd init my-node --chain-id cosmos-evm-1
Node Status
Transaction Indexing
evmd index-eth-tx forward
Account Management
Key Operations
Ethereum Key Import/Export
evmd keys unsafe-export-eth-key my-eth-account
Account & Balance Queries
evmd query evm account 0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb81
Contract Queries
evmd query evm code 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48
Configuration & Parameters
Address Conversion
evmd query evm 0x-to-bech32 0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb81
Token Pair Queries
evmd query erc20 token-pairs
evmd query feemarket base-fee
Precision Banking
evmd query precisebank remainder
Bank Module
evmd query bank balances cosmos1wsk4trnzfszs55jlt5ugz76lwl2hp04slh5s5s
Staking Module
evmd query staking validators
Distribution Module
evmd query distribution rewards \
cosmos1wsk4trnzfszs55jlt5ugz76lwl2hp04slh5s5s \
cosmosvaloper1xyz...
Governance Module
EVM Transfers
evmd tx evm send \
my-account \
0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb81 \
1000000atest \
--gas-prices 10atest
Token Conversions
evmd tx erc20 convert-coin \
1000000atest \
0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb81 \
--from my-account \
--gas-prices 10atest
Governance Operations
evmd tx erc20 register-erc20 \
0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 \
--from validator
Bank Transactions
evmd tx bank send \
my-account \
cosmos1abc... \
1000000atest \
--gas-prices 10atest
Staking Transactions
evmd tx staking delegate \
cosmosvaloper1abc... \
1000000atest \
--from my-account \
--gas-prices 10atest
Governance Transactions
evmd tx gov submit-proposal \
--title="Upgrade Proposal" \
--description="Upgrade to v2.0.0" \
--type="Text" \
--deposit="1000000atest" \
--from my-account
Genesis Operations
evmd genesis add-genesis-account \
cosmos1abc... \
1000000000atest
CometBFT Commands
Debug Utilities
evmd debug addr cosmos1abc...
Examples
Complete Workflows
Account Setup
Query Examples
Transactions
# Create new Cosmos account
evmd keys add my-account
# Save mnemonic safely!
# Address will be shown as cosmos1...
# Query Cosmos account
evmd query bank balances \
cosmos1wsk4trnzfszs55jlt5ugz76lwl2hp04slh5s5s
# Query EVM account
evmd query evm account \
0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb81
# Send tokens via bank module
evmd tx bank send \
my-account \
cosmos1abc... \
1000000atest \
--gas-prices 10atest \
--gas-adjustment 1.5
Configuration
- Configuration directory:
~/.evmd/
- Key storage: Managed by the keyring backend (os, file, test)
- Node configuration:
~/.evmd/config/config.toml
- App configuration:
~/.evmd/config/app.toml
If you use the --home flag upon initializing the light client, the root/config directory will be generated there