1/5
### Uniswap V3 Contracts There are a few important contracts that we need to know to interact with Uniswap V3. These contracts are split into several repositories, specifically: * v3-periphery * v3-core * swap-router-contracts * universal-router Within the v3-periphery repository, the most important contract to remember is called the NonfungiblePositionManager. This contract will manage our position when we add and remove liquidity and to collect fees. Two important contracts inside the v3-core repository are: * UniswapV3Factory contract * UniswapV3Pool contract The UniswapV3Factory will deploy the UniswapV3Pool contract, which will hold two tokens, add and remove liquidity, and where we will be able to call swaps on. Similar to Uniswap V2, the pool contract is a low-level contract. To interact with it we will need another contract. Similar to Uniswap V2, we had the Uniswap V2 Pair and Router contracts; in Uniswap V3 we also have a pool and router contract. The main router contract that we will be using is called SwapRouter02. This contract is inside the swap-router-contracts repository. This contract has been upgraded to another contract inside the universal-router repository: the universal-router contract. The universal-router contract is a more comprehensive contract that will allow us to swap between Uniswap V2, V3 and some NFTs. However, for this course we won't touch on this universal-router contract and will instead look at the SwapRouter02 contract.
A comprehensive guide to Uniswap V3 contracts - This lesson will cover the key contracts within the Uniswap V3 ecosystem, including the V3-periphery, V3-core, and the universal-router contracts. You'll learn how these contracts work together to facilitate liquidity provision and trading on Uniswap V3.
Previous lesson
Previous
Next lesson
Next
Give us feedback
Course Overview
About the course
Concentrated liquidity and derive its equations
Uniswap V3 math
How to calculate the spot price of tokens
Single and multi position swapping
Factory contract architecture
How to calculate liquidity requirements
Uniswap V3 fee algorithm
Flash loans
TWAP price oracle
Smart Contract Auditor
$100,000 - $200,000 (avg. salary)
Blockchain Financial Analyst
$100,000 - $150,000 (avg. salary)
DeFi Developer
$75,000 - $200,000 (avg. salary)
Smart Contract Engineer
$100,000 - $150,000 (avg. salary)
Web3 developer
$60,000 - $150,000 (avg. salary)
Web3 Developer Relations
$85,000 - $125,000 (avg. salary)
Last updated on May 15, 2025
DeFi Developer
Uniswap V3Duration: 3min
Duration: 35min
Duration: 25min
Duration: 22min
Duration: 1h 43min
Duration: 11min
Duration: 1h 03min
Duration: 12min
Duration: 51min
Duration: 41min
Duration: 10min
Duration: 7min
Course Overview
About the course
Concentrated liquidity and derive its equations
Uniswap V3 math
How to calculate the spot price of tokens
Single and multi position swapping
Factory contract architecture
How to calculate liquidity requirements
Uniswap V3 fee algorithm
Flash loans
TWAP price oracle
Smart Contract Auditor
$100,000 - $200,000 (avg. salary)
Blockchain Financial Analyst
$100,000 - $150,000 (avg. salary)
DeFi Developer
$75,000 - $200,000 (avg. salary)
Smart Contract Engineer
$100,000 - $150,000 (avg. salary)
Web3 developer
$60,000 - $150,000 (avg. salary)
Web3 Developer Relations
$85,000 - $125,000 (avg. salary)
Last updated on May 15, 2025