Local Network and Forking
Test environments.
The Hardhat Network
Hardhat ships with a built-in local Ethereum network designed for development. It runs in-memory, mines blocks instantly, and gives you funded test accounts.
- No real ETH or gas costs.
- Deterministic accounts you can reuse.
- Rich error messages and stack traces.
Starting a Local Node
Run a standalone JSON-RPC server so wallets and front-ends can connect:
npx hardhat nodeThis prints 20 funded accounts with their private keys and listens on http://127.0.0.1:8545.
npx hardhat nodeAll lessons in this course
- Hardhat Setup
- Compiling Contracts
- Scripts and Tasks
- Local Network and Forking