Skip to main content
TLDR:
  • Shows how to deploy the entire Uniswap v3 suite onto Scroll Mainnet in a few steps
  • Guides through setting up the v3 deploy repository, configuring a Scroll RPC endpoint, and specifying WETH and admin settings
  • Explains core Uniswap v3 contracts (Router, Factory, NFT positions, migrator, etc.) and how they compose the AMM
  • Emphasizes the Scroll environment’s hierarchical ZKP optimizations, making this deployment straightforward and efficient

What is Scroll?

Scroll network is a new scaling solution for Ethereum that uses zero-knowledge proofs to make transactions fast, secure, and cheap. It’s fully compatible with the EVM (Ethereum Virtual Machine), so developers can easily port their DApps to Scroll without any changes. Chainstack supports Scroll Mainnet, which makes it even easier for developers to get started. In this tutorial, you’ll learn how to deploy the full Uniswap v3 AMM suite on Scroll in just a few easy steps.

Why use Scroll?

Scroll’s hierarchical ZKP system is optimized for both provers and verifiers, allowing it to achieve faster transaction finality and lower gas fees than other layer-2 scaling solutions. The first layer of Scroll’s ZKP system is optimized for provers, using custom circuit optimization and hardware-friendly proving algorithms. This allows provers to generate proofs much faster, reducing the overall transaction latency. The second layer of Scroll’s ZKP system is optimized for verifiers, using succinct proofs and verification algorithms compatible with the EVM. This allows verifiers to verify proofs much faster, reducing the overall transaction cost. As a result of its hierarchical ZKP system, Scroll is able to achieve much faster transaction finality and lower gas fees than other layer-2 scaling solutions. This makes it a great choice for applications that require high throughput and low latency, such as DeFi and NFT trading.

Prerequisites

Overview

This tutorial shows you how to deploy the Uniswap V3 smart contracts on Scroll Mainnet. To get from zero to a deployed instance of Uniswap V3, do the following:
  1. With Chainstack, create a .
  2. With Chainstack, join Scroll Mainnet.
  3. With Chainstack, access your Scroll Mainnet node endpoint.
  4. Fund your wallet with ETH on Scroll.
  5. Deploy the Uniswap v3 suite.

Step-by-step

Create a public chain project

See Create a project.

Join Scroll Mainnet

See Join a public network.

Get your Scroll Mainnet node endpoint

See View node access and credentials.

Fund your wallet

Deploying on Scroll Mainnet spends real ETH. Fund your deployer wallet with ETH on Scroll by bridging from Ethereum Mainnet with the Scroll Bridge, or by withdrawing to Scroll from an exchange that supports it.
This deploys to mainnet and spends real funds. Budget roughly 0.5 ETH as a safe buffer for the full suite, and confirm the current Scroll gas price before you deploy.

Deploy the Uniswap v3 suite

In this step, we will deploy the full Uniswap v3 AMM suite on Scroll network. And we will leverage the v3 deploy official repository to automate the process. The repository contains a CLI script for deploying the latest Uniswap v3 smart contracts to any EVM-compatible network. This repository collects almost all of the contracts that make up Uniswap v3 and provides scripts to deploy them easily in a single command. Uniswap is one of the most popular decentralized finance (DeFi) solutions in the Web3 space. Uniswap v3 is the third major version of Uniswap, and it allows users to swap ERC-20 tokens without a centralized intermediary. Since its launch in May 2021, Uniswap v3 has quickly become the most popular DeX in the world, with over $100 billion in total value locked.

Set up the CLI

  1. Clone the repository:
  2. Make sure you install TypeScript V4.2.3:
  3. Move into the repository’s directory:
  4. Install the dependencies and build:
The console should have a similar output:

Deploy the smart contracts

For the next step, you will need the following:
  • The private key of the account deploying the smart contracts, starting with 0x
  • The Chainstack Scroll Mainnet HTTPS endpoint
  • The address of the account that will manage the smart contracts
In the console, run the following command, adding your private key, endpoint, and address:
Here is a list of what the flags mean:
  • -pk — your deployment account’s private key.
  • -j — the JSON-RPC endpoint.
  • -w9 — the address of the WETH9 contract. On Scroll Mainnet, WETH9 is deployed at 0x5300000000000000000000000000000000000004.
  • -ncl — the native currency label. This is the symbol for the native token, which is ETH.
  • -o — the owner’s address of the deployed administrator contract.
Below is the full list of options:
Running this command will deploy the contracts one by one; the console will display each deployment like the following:
You can also find the details of the contracts in the state.json file. Congratulations, you deployed all of the Uniswap v3 smart contracts on Scroll Mainnet.
Use the block explorer to see the transactions.

Understanding the smart contracts

UniswapV3Factory

The UniswapV3Factory contract is the central hub for all Uniswap v3 pools. It allows users to create new pools, query information about existing pools, and add or remove liquidity from pools. The UniswapV3Factory contract is also responsible for managing the protocol fees for all Uniswap v3 pools.

UniswapInterfaceMulticall

UniswapInterfaceMulticall is a helper contract allowing users to group multiple function calls into one call. This can be useful for reducing the number of transactions that need to be sent to the blockchain and ensuring that all calls are executed in the same block.

ProxyAdmin and TransparentUpgradeableProxy

A proxy gateway contract is a smart contract that allows for the easy upgrade of other smart contracts. This is essential for any project that wants to evolve over time without having to fork the blockchain.

TickLens

The TickLens contract is a peripheral contract in the Uniswap v3 protocol. It provides functions for querying information about the ticks in a Uniswap v3 pool. The TickLens contract can be used to:
  • Find out how many ticks are in a pool.
  • Determine which ticks are initialized.
  • Identify which ticks have liquidity.

NonfungibleTokenPositionDescriptor and NonfungiblePositionManager

The NonfungibleTokenPositionDescriptor contract stores the ID of NFTs and their respective NonFungiblePositionManger contract address. The NonfungiblePositionManager manages the positions and liquidity for ERC-721 non-fungible tokens.

V3Migrator

The V3Migrator contract is a tool that helps developers migrate their Uniswap v2 pools to Uniswap v3.

UniswapV3Staker

The UniswapV3Staker contract is a peripheral contract in the Uniswap v3 protocol. It allows users to stake their ERC-20 tokens in Uniswap v3 pools in order to earn rewards. The rewards are paid out as the pool’s native token. The UniswapV3Staker contract is critical to the Uniswap v3 protocol because it incentivizes liquidity provision. By allowing users to earn rewards for staking their tokens, the UniswapV3Staker contract helps to ensure that there is always enough liquidity in Uniswap v3 pools to facilitate swaps. This makes the protocol more decentralized and efficient.

QuoterV2 and SwapRouter02

The Quoter and SwapRouter contracts are essential for users who want to exchange tokens on Uniswap. QuoterV2 is a peripheral contract in the Uniswap v3 protocol. It allows users to get price quotes for swaps without executing the swap. QuoterV2 uses the Uniswap v3 core, periphery contracts, and the PoolTicksCounter library. It includes functions to quote exact input or output amounts and handles reverts by counting initialized ticks crossed. SwapRouter02 executes swaps across different asset pools. It is a stateless contract, meaning it holds no token balances. This makes it more efficient and secure than other types of contracts. The SwapRouter contract considers the price of tokens, the liquidity in different pools, and the fees for swaps to calculate the best price for a swap. It then executes the swap, transferring tokens between pools and updating users’ balances.

Conclusion

In conclusion, deploying Uniswap v3 on Scroll is a relatively straightforward process. Following the steps outlined in this tutorial, you can create a Uniswap v3 pool on Scroll in just a few minutes. Once your pool is deployed, you can start providing liquidity and earning fees.

About the author

Wuzhong Zhu

Wuzhong Zhu Developer Advocate @ Chainstack
BUIDLs on Ethereum, zkEVMs, and The Graph protocol
Last modified on July 14, 2026