foundry

Develop, test, and deploy EVM smart contracts with Foundry.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/0xinit/cryptoskills --skill foundry-0xinit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: foundry
Source: https://github.com/0xinit/cryptoskills/tree/main/skills/foundry
Command: npx skills add https://github.com/0xinit/cryptoskills --skill foundry-0xinit

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides a comprehensive toolkit and best practices for developing, testing, and deploying smart contracts on EVM-compatible blockchains using the Foundry framework.

Core Features & Use Cases

  • Development Workflow: Covers project setup, compilation, and dependency management.
  • Testing: Demonstrates unit, fuzz, invariant, and fork testing patterns with detailed cheatcode usage.
  • Deployment: Guides through script-based deployment, verification, and common deployment issues.
  • Use Case: A Solidity developer needs to write robust tests for a new DeFi protocol, deploy it to a testnet, and verify the contract. This Skill provides the exact commands and patterns to achieve this efficiently.

Quick Start

Use the foundry skill to set up a new smart contract project and run its tests.

Frequently Asked Questions about foundry

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up a Foundry project for EVM smart contract development?

Foundry provides a complete development environment for EVM smart contracts, allowing you to initialize projects, compile Solidity code, and manage dependencies using its built-in project scaffolding and workflow commands.

What is the best way to test smart contracts using Foundry?

The best way to test smart contracts using Foundry is by utilizing its advanced testing methodologies, which include writing unit tests, applying fuzzing to find edge cases, and running invariant tests to verify protocol-wide state guarantees.

Can I run fork testing on mainnet state with Foundry?

Yes, Foundry supports fork testing, allowing you to execute tests against real EVM blockchain state by utilizing specific testing cheatcodes to manipulate the environment and verify interactions with deployed contracts.

How do I deploy and verify Solidity contracts using Foundry scripts?

To deploy and verify Solidity contracts using Foundry scripts, you write a deployment script and execute it with the appropriate broadcast commands, which handles the EVM transaction and allows you to submit verification automatically.

Do I need to know Solidity before using Foundry for smart contract deployment?

Yes, you need familiarity with Solidity and blockchain concepts to use Foundry for smart contract deployment. The framework requires this prerequisite knowledge to effectively write, test, and deploy EVM contracts.

What are Foundry cheatcodes and how do they work in EVM testing?

Foundry cheatcodes are special EVM instructions used during testing to manipulate the blockchain state, mock data, or change block timestamps. They work by allowing your test scripts to assert specific contract behaviors under controlled conditions.