fhEVM
WebsiteLibrariesProduct & ServicesDevelopersSupport
0.6
0.6
  • Welcome to fhEVM
  • White paper
  • Getting Started
    • Overview
    • Quick Start
      • Remix
        • 1. Setting up Remix
        • 2. Connect your wallet to Remix
        • 3. Deploying ConfidentialERC20
        • 4. Interacting with the contract
      • Hardhat
        • Prerequisites
        • 1. Setting up Hardhat
        • 2. Writing contracts
        • 3. Testing in mocked mode
        • 4. Deploying the contract
        • 5. Interacting with the contract
  • Tutorials
    • See all tutorials
  • Smart contract
    • Key features
    • Configuration
    • FhEVM contracts
    • Supported types
    • Operations on encrypted types
    • Access Control List
      • ACL examples
    • Encrypted Inputs
    • Decryption
      • Decryption
      • Decryption in depth
      • Re-encryption
    • If sentences
    • Branching in FHE
    • AsEbool, asEuintXX, asEaddress and asEbytesXX operations
    • Generate random numbers
    • Error handling
    • Gas estimation
    • Debug decrypt
    • Using Foundry
  • Frontend
    • Setup
    • Build a web application
    • Using React.js
    • Using Next.js
    • Using Vue.js
    • Using Node or Typescript
    • Using the CLI
    • Common webpack errors
  • Explanations
    • Architectural overview
    • FHE on blockchain
    • fhEVM components
    • Encryption, decryption, re-encryption, and computation
  • References
    • Table of all addresses
    • Smart contracts - fhEVM API
    • Frontend - fhevmjs lib
    • Repositories
  • Developer
    • Contributing
    • Development roadmap
    • Release note
    • Feature request
    • Bug report
    • Status
Powered by GitBook

Libraries

  • TFHE-rs
  • Concrete
  • Concrete ML
  • fhEVM

Developers

  • Blog
  • Documentation
  • Github
  • FHE resources

Company

  • About
  • Introduction to FHE
  • Media
  • Careers
On this page
  • What You’ll Learn
  • Prerequisite
  • What is Confidenetial ERC20
  • Next steps

Was this helpful?

Export as PDF
  1. Getting Started

Quick Start

PreviousOverviewNextRemix

Last updated 2 months ago

Was this helpful?

This tutorial guides you to start quickly with Zama’s Fully Homomorphic Encryption (FHE) technology for building confidential smart contracts.

What You’ll Learn

In about 20 minutes, you will:

  • Build your first confidential ERC20 contract that leverages FHE.

  • Deploy the contract on the Sepolia Network.

  • Mint tokens and perform transactions in FHE.

Prerequisite

  • A basic understanding of Solidity library and Ethereum.

  • A certain amount of Sepolia ETH available.

    • If you don’t have enough ETH, use a Sepolia faucet to request free SepoliaETH for testing such as or .

What is Confidenetial ERC20

The contract that you will build with this tutorial is called ConfidentialERC20Mintable — a privacy-preserving ERC20 implementation that leverages FHE to keep balances and transactions confidential. To understand this contract, let’s first introduce the foundational concepts.

RC20

ERC20 is a widely used token standard on Ethereum that defines a set of rules for creating and managing fungible tokens. These tokens are efficient but lack privacy — balances and transactions are visible to anyone on the blockchain.

Confidential ERC20

Zama’s ConfidentialERC20 introduces privacy to ERC20 tokens by storing balances and transactions in an encrypted format using FHE.

The ConfidentialERC20 contract still supports standard ERC20 functions such as transfer, approve, transferFrom, balanceOf, and totalSupply but ensures these operations are processed securely with encrypted data.

Confidential ERC-20 Mintable

The contract that we will build in this tutorial is ConfidentialERC20Mintable . It's built on top of ConfidentialERC20 by adding secure minting capabilities. This allows authorized accounts to create new tokens, while maintaining the privacy guarantees of encrypted balances and transactions.

The ConfidentialERC20Mintable contract ensures:

  • Enhanced privacy: Balances are stored as encrypted values (euint64), preventing public inspection of account balances.

  • Secure transactions: Token transfers are processed securely, maintaining confidentiality of amounts.

  • Owner visibility: Only account owners can decrypt and view their balances.

Next steps

Choose your path and get started:

To explore the implementation details of ConfidentialERC20, check out the .

– Rapid in‐browser setup, great for learning and fast prototyping.

– Full-fledged development environment, suitable for production.

Alchemy Faucet
QuickNode Faucet
Zama blog post
Remix Guide
Hardhat Guide