Open-source project
Uniswap/v3-core avatar
Uniswap/v3-core

Uniswap v3-core: what actually ships to npm, and under which license

🦄 🦄 🦄 Core smart contracts of Uniswap v3

5,075 stars3,025 forksTypeScriptNOASSERTION

At a glance

What is it?
Uniswap v3-core holds the core smart contracts for the Uniswap V3 protocol, published to npm as @uniswap/v3-core under BUSL-1.1 with directory level license carve-outs. The package's files list has five entries and one exclusion, and it declares no runtime dependencies, and it points local deployments at the published bytecode instead of a local compile.
Who is it for?
Uniswap v3-core is the right dependency for anything that needs the pool and factory bytecode or the Solidity interfaces, and the wrong place to look for the router, quoter or the rest of the trading surface, which lives in uniswap-v3-periphery.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Yes. The repository last received commits 23 days ago.
What is it written in?
Mainly TypeScript, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 15, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • Uniswap/v3-core5,075 ★ · +52
Star history
Repository2026-09-232026-11-15
Uniswap/v3-core5k5.1k

52 Stars in the last 53 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

Local deployments should import the published factory bytecode

The repository does not tell you to compile its own copy for a testnet run. It tells you to install the npm package `@uniswap/v3-core` and import the factory bytecode from the build artifact path:

typescript
import {
  abi as FACTORY_ABI,
  bytecode as FACTORY_BYTECODE,
} from '@uniswap/v3-core/artifacts/contracts/UniswapV3Factory.sol/UniswapV3Factory.json'

// deploy the bytecode

The stated reason is worth repeating because it is the whole argument for the approach: testing against that artifact means you are running the same bytecode that is deployed to mainnet and the public testnets, and other Uniswap code will interoperate correctly with your local deployment. Compile-from-source locally and you get a second implementation whose behaviour can drift from the one the rest of the ecosystem already trusts.

The published files list is four entries and one exclusion

The manifest's `files` array is short enough to read in one breath, and it defines what anyone installing the package actually receives. Four things ship: the `contracts/interfaces` directory, the `contracts/libraries` directory, the artifact JSON for `UniswapV3Factory.sol`, and the artifact JSON for `UniswapV3Pool.sol`. A fifth pattern, `artifacts/contracts/interfaces/**/*.json`, pulls in the compiled interface artifacts, with one explicit exclusion, `!artifacts/contracts/interfaces/**/*.dbg.json`, so the debugger sidecar files stay out of the tarball.

That list has a consequence worth planning around. The compiled pool implementations do not travel as Solidity source; you get them through the two artifact files, while the Solidity you can read and import is limited to the interfaces and the libraries. The package itself is published with `publishConfig.access` set to public, carries `dependencies` as an empty object, and declares an engine requirement of node 10 or newer. So consuming the package costs you nothing in transitive runtime dependencies, and integrating it is a matter of picking the right entry point rather than resolving a dependency tree.

Solidity consumers import the interface path directly

For a contract that only needs to talk to a pool, the route is a plain import of the published interface:

solidity
import '@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool.sol';

contract MyContract {
  IUniswapV3Pool pool;

  function doSomethingWithPool() {
    // pool.swap(...);
  }
}

Two things make that path viable. The first is that `contracts/interfaces` is one of the directories the package publishes, so the import resolves from node_modules without a build step of your own. The second is the licensing arrangement described below, which gives a Solidity consumer a GPL-2.0-or-later option for the interface surface.

Scope is the thing to keep straight. This repository holds the core contracts for the protocol, and the higher level contracts live in a separate uniswap-v3-periphery repository. If you are looking for periphery behavior such as routing through multiple pools, quoting, or the periphery test helpers, none of it is in this package, and the interface file you just imported is the boundary of what v3-core exposes.

BUSL-1.1 is the default, with license changes at the directory level

The primary license is the Business Source License 1.1, spelled `BUSL-1.1` in both the README and the manifest, with the terms in the LICENSE file at the repository root. On top of that default, four exceptions are spelled out, and each one is verified through SPDX headers rather than by file name.

Every file in `contracts/interfaces/` may also be licensed under `GPL-2.0-or-later`, as indicated in its SPDX header, with the terms in `contracts/interfaces/LICENSE`. Several files in `contracts/libraries/` may also be licensed under `GPL-2.0-or-later` on the same basis, with terms in `contracts/libraries/LICENSE`. One named file breaks out in the other direction: `contracts/libraries/FullMath.sol` is MIT, stated in its SPDX header, with the text at `contracts/libraries/LICENSE_MIT`. Finally, everything under `contracts/test` remains unlicensed, again per its SPDX headers.

For a compliance review that means four questions rather than one: which license you are relying on for the interfaces, which for the libraries you import, whether FullMath is in that set, and whether anything you copied came from the unlicensed test directory.

The test stack is Hardhat 2 with ethers v5 and Waffle

The manifest exposes two scripts and nothing else: `compile` runs `hardhat compile`, and `test` runs `hardhat test`. Everything else you would expect in a repository's script table is absent, which matches a package whose job is to be imported rather than run.

The development dependencies describe the era of the toolchain. Hardhat is on `^2.2.0`, joined by `@nomiclabs/hardhat-ethers` at `^2.0.2`, `ethers` at `^5.0.8` and `ethereum-waffle` at `^3.0.2`, with `chai` `^4.2.0` and `mocha` `^6.2.2` underneath. Contract types are generated with `typechain` `^4.0.0` and `ts-generator` `^0.1.1`, `hardhat-typechain` and `@typechain/ethers-v5` wiring the two together, and TypeScript sits at `^3.7.3`. Linting and formatting run through `solhint` `^3.2.1` with a prettier plugin, backed by `prettier` `^2.0.5` and the `.prettierrc` and `.solhint.json` files at the root, plus a `yarn.lock` and a `.yarnrc`.

The practical note for anyone cloning the repository is that this is a 2021 era dependency set, so the versions in the lockfile, not the latest releases, are what the tests are written against.

Four workflows gate the contracts, two of them fuzzing oriented

Four GitHub Actions workflows are linked from the top of the README, and the file names say what the project considers worth automating. There is a lint workflow and a tests workflow, then a fuzz-testing workflow and a mythx workflow. The presence of `echidna.config.yml` at the repository root confirms that side of the pipeline is configuration driven rather than a single hardhat task.

The repository layout backs this up. `contracts/` holds the Solidity, `test/` the suite that `hardhat test` runs, `audits/` the published audit reports, and `bug-bounty.md` the terms of the Uniswap V3 bug bounty program that this repository is subject to. Configuration files sit at the root rather than in a config directory: `hardhat.config.ts`, `tsconfig.json`, `.solhint.json`, `.prettierrc`, `.gitattributes`.

For a reader deciding how much to trust the bytecode they are about to import, the audits directory and the bug bounty terms are the two things to read first, and the fuzzing workflow is the reason to believe the invariant tests are more than unit tests with nicer names.

No GitHub releases, so the npm version is the version of record

There is nothing to look at in the release tab, because the repository publishes no GitHub releases at all. The version of record lives in the manifest, where `version` is `1.0.1` and the package name is `@uniswap/v3-core`. The default branch is main and the last push landed on 23 October 2026, which is recent enough that the tree is not abandoned but also not a place where a new tag is being cut for you to follow.

That has a direct effect on how you should consume this package. There is no changelog to diff, no upgrade guide between core versions, and no release artifact beyond whatever npm serves. If you are pinning a dependency on the core contracts, pin the exact version and treat an upgrade as a deliberate review of the compiled artifacts rather than a routine bump, because the bytecode in `artifacts/contracts/UniswapV3Factory.sol/UniswapV3Factory.json` and `artifacts/contracts/UniswapV3Pool.sol/UniswapV3Pool.json` is the thing you are actually deploying.

Editorial conclusion

Uniswap v3-core is the right dependency for anything that needs the pool and factory bytecode or the Solidity interfaces, and the wrong place to look for the router, quoter or the rest of the trading surface, which lives in uniswap-v3-periphery. Before you depend on it, decide which license you actually need, since the interfaces and part of the libraries directory offer a GPL-2.0-or-later alternative and everything in contracts/test is unlicensed, then check the audit reports under audits/ and the bug bounty terms in bug-bounty.md against your own threat model. Note also that there are no GitHub releases here, so the npm version 1.0.1 is the only version record to pin against.

Frequently asked questions

What license is Uniswap v3-core published under?

The primary license is the Business Source License 1.1 (`BUSL-1.1`). Files in `contracts/interfaces/` and several files in `contracts/libraries/` may also be used under `GPL-2.0-or-later` as their SPDX headers indicate, `contracts/libraries/FullMath.sol` is MIT, and everything under `contracts/test` remains unlicensed.

How do I deploy Uniswap v3-core to a local testnet?

Install the `@uniswap/v3-core` npm package and import the factory bytecode from `@uniswap/v3-core/artifacts/contracts/UniswapV3Factory.sol/UniswapV3Factory.json`, rather than compiling the repository yourself. The point is to test against the same bytecode deployed to mainnet and the public testnets so other Uniswap code interoperates correctly.

What files does the @uniswap/v3-core npm package contain?

The `files` array publishes `contracts/interfaces`, `contracts/libraries`, the UniswapV3Factory and UniswapV3Pool artifact JSON files, and the compiled interface artifacts under `artifacts/contracts/interfaces/**/*.json`, excluding the `.dbg.json` sidecars. The package declares no runtime dependencies and requires node 10 or newer.

How do I run the Uniswap v3-core tests?

The manifest exposes two scripts: `compile` runs `hardhat compile` and `test` runs `hardhat test`. The stack behind them is Hardhat 2, ethers v5, ethereum-waffle, chai and mocha, with TypeScript 3.7 and typechain for contract types.

Official sources

  1. Issues
  2. Project website
  3. README
  4. Uniswap/v3-core on GitHub
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/uniswap-v3-core.svg)](https://hysenlabs.com/projects/uniswap-v3-core)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/uniswap-v3-core.svg)](https://hysenlabs.com/projects/uniswap-v3-core)

Was this useful?