Skip to main content
This guide walks you through creating a project, starting the development environment, and running your first tests.

Step 1: Create a Project

Scaffold a new project from a built-in template:
This creates a my-dapp/ directory with:
my-dapp
dokrypt.yaml
foundry.toml
contracts
Counter.sol
SimpleToken.sol
test
Counter.t.sol
SimpleToken.t.sol
scripts
deploy.js
README.md
Use dokrypt template list to see all 5 available templates: evm-basic, evm-token, evm-nft, evm-dao, evm-defi.

Step 2: Start the Environment

Dokrypt pulls the required Docker images and starts a local Anvil blockchain node:
Your local chain is now running at http://localhost:8545 with 10 pre-funded accounts.

Step 3: Check Status

Step 4: Run Tests

Dokrypt discovers and runs your Solidity tests:
Add --gas-report for gas analysis:

Step 5: Use Chain Utilities

While your environment is running, you can manipulate the chain:

Step 6: Save a Snapshot

Save the current chain state so you can restore it later:
After making changes, restore it:

Step 7: Fork Mainnet

Test against real protocol state by forking a live network:
Now your local chain has the full state of Ethereum mainnet at block 18,500,000. You can interact with Uniswap, Aave, and any other deployed contracts.

Step 8: Stop the Environment

Add --volumes to remove persistent data:

Next Steps

Configuration

Learn the full dokrypt.yaml configuration format.

Templates

Explore DeFi, NFT, DAO, and Token templates.

Snapshots

Master state snapshot management.

Chain Forking

Fork any EVM chain for testing.