What is Uniswap? A guide to how Uniswap (UNI) works (2024)

guidedefi

0 minsPublished on 12/19/2023

Read this guide to learn about Uniswap, the DEX that revolutionized crypto trades with its automated market maker (AMM) model and liquidity pools.

By Corey Barchat

What is Uniswap? A guide to how Uniswap (UNI) works (1)

The vast majority of crypto trades take place on centralized exchanges (CEXs) and decentralized exchanges (DEXs).

The former requires a handover of assets to a centralized authority, while the latter requires buyers and sellers to provide liquidity to order books. And on a decentralized exchange, trades cannot be executed efficiently if there’s low liquidity.

This is where Uniswap comes in. Uniswap uses a decentralized trading model called an automated liquidity protocol to improve liquidity and make cryptocurrency trades more efficient. But it's more complicated than that.

In this article, we’ll dive deeper into what Uniswap is, how it works and how it differs from traditional order books and centralized exchanges.

What is Uniswap?

Uniswap is a decentralized cryptocurrency exchange built on the Ethereum blockchain and compatible with Layer 2s like Arbitrum, Base, and Optimism. It pools liquidity and uses a deterministic algorithm to calculate the price of crypto assets, rather than relying on buyers and sellers. This enables traders to make token swaps across all price ranges without running out of coins.

Unlike traditional cryptocurrency exchanges, Uniswap employs an Automated Market Maker (AMM) model, which has revolutionized the way we trade cryptocurrencies. Rather than making trades directly with another party, AMMs make it easier for users to trade tokens against liquidity stored in smart contracts.

At its core, the Uniswap protocol allows users to swap various Ethereum-based tokens directly from a non-custodial wallet, while staying in full control of their digital assets.

How does Uniswap work?

Technically speaking, Uniswap is powered by two smart contracts: the "Exchange" contract and the "Factory" contract. The former handles token swaps (or trades) and the latter adds new tokens to the Uniswap platform.

At its heart, Uniswap is built on several core features that underpin its unique functionality:

  1. Automated liquidity protocol: Uniswap's automated market maker (AMM) model removes the need for traditional order books and instead relies on liquidity pools to facilitate trades, automatically calculating the exchange rate based on the pool's reserves.
  2. Permissionless: Uniswap is a decentralized platform, meaning anyone can create a new liquidity pool or add liquidity to an existing one. This permissionless nature helps democratize and decentralize the token exchange process.
  3. Liquidity provision: Users can swap tokens and provide liquidity to the platform. Liquidity providers receive a share of the trading fees generated by other users performing Uniswap transactions.
  4. Constant product formula: Uniswap uses a mathematical formula to maintain constant liquidity within its pools. This formula ensures that the product of the reserve amounts for two tokens in a pool remains the same before and after a trade.

Since Uniswap is an ETH-based exchange, you can only swap ERC-20 tokens with each other. To understand how it works, let’s look at the function of its liquidity protocol:

Uniswap liquidity pools

Uniswap's liquidity pools ensure that tokens are always available for trading. These pools are created by users called liquidity providers who contribute both of the tokens in trading pairs, typically in equal value. Liquidity pools enable users to exchange tokens seamlessly, and reward providers with transaction fees for their participation.

How liquidity pools work

Each liquidity pool in Uniswap contains a unique token pair and anyone can contribute liquidity to it. When you provide liquidity to a Uniswap pool, you deposit an equal value of two tokens into the pool.

When the LP mints a pool for the first time, they’ll get x.y tokens, where x and y are the amount of each token they provided. After the first mint, Uniswap calculates the proportion of the pool’s liquidity provided to determine how many liquidity tokens the LP should get.

What is Uniswap? A guide to how Uniswap (UNI) works (2)

For instance, if you want to create a liquidity pool for ETH and DAI, you would deposit an equal value of both ETH and DAI. The liquidity pool will automatically calculate the exchange rate based on the amount of each token in the pool, and you'll be rewarded with LP tokens earned from other users making trades between Ethereum and Dai on the Uniswap platform.

The role of liquidity providers

Liquidity providers play a vital role in the Uniswap ecosystem. They earn a share of the trading fees generated by the platform, which incentivizes them to participate. It's a way for users to earn passive income while helping to maintain the liquidity of the platform.

What is Uniswap? A guide to how Uniswap (UNI) works (3)

For example, if you provide 10% of the pool’s liquidity, your token will entitle you to 10% of the liquidity available in the pool. In case new tokens are added or removed, Uniswap will mint or burn liquidity tokens to ensure that everyone’s relative percentage share remains the same.

Alternatively, liquidity providers can also sell, trade or transfer their LP tokens, since these are tradable assets. To withdraw liquidity, users can burn liquidity tokens and exchange them for the liquidity in the pool, along with the proportional fee allocation.

Token swapping

Swapping tokens on Uniswap is a straightforward process. Users select the tokens they want to swap, and the platform calculates the exchange rate based on the liquidity pool's reserves. The conversion is executed instantly, making it a user-friendly experience for traders.

For step-by-step instructions to exchange tokens on Uniswap, read our Token Swaps guide.

The Uniswap (UNI) token

What is the UNI token?

UNI is Uniswap's native token, introduced to give users a say in the platform's development and decision-making. As a governance token, UNI gives holders the ability to vote on proposals that shape the platform's future.

Why was the UNI token created?

In 2020, Uniswap launched the UNI governance token, which allowed anyone who held more than 1% of the available tokens to submit and vote on proposals that further the development of the protocol.

The idea behind the launch was to create a system that’s both decentralized and self-sustaining, and prevent users from switching to a competitor DEX, such as SushiSwap, a Uniswap clone.

To compete with Uniswap, SushiSwap started luring users with SUSHI tokens. Uniswap retaliated by minting 1 billion UNI tokens and airdropping them to 150 million users on the network.

What is Uniswap? A guide to how Uniswap (UNI) works (4)

Each user—anyone who interacted with the contract, including the 12,000 addresses that had only submitted failed transactions—was eligible to claim 400 UNI tokens at the time, which was roughly equivalent to $1,000.

Uniswap (UNI) token allocation (1 billion total)

  • 60% to Uniswap community members [600 million UNI]
  • 21.26% to team members and future employees with 4-year vesting [213 million UNI]
  • 18% to investors with 4-year vesting [180 million UNI]
  • .069% to advisors with 4-year vesting [7 million UNI]

How does governance work on Uniswap?

Uniswap operates with a decentralized autonomous organization (DAO) structure. This means that decisions about the platform's future are made by UNI token holders through a voting mechanism.

Generally speaking, the more UNI tokens you hold, the more voting power you have. If you're a UNI holder, you can head to the Governance Forum to view, discuss, and vote on newly introduced proposals.

Recently voted UNI proposals

UNI token holders actively participate in shaping Uniswap's future. Some recent proposals voted on include changes to fee structures, grants for development projects, and the introduction of new features to the Uniswap protocol.

What is Uniswap? A guide to how Uniswap (UNI) works (5)

This governance model ensures that the Uniswap protocol evolves in a way that aligns with the interests of its community.

How does Uniswap determine token prices?

On the Uniswap platform, a proportional amount of tokens must be deposited or sold when tokens are withdrawn to maintain a balanced liquidity pool. Uniswap does this using a mathematical formula called the constant product formula:

k = x.y

According to this formula, k is a constant and x and y are the ERC-20 tokens being traded.

When the pool is first created, the LP determines this constant k. But once trades start taking place, this value grows or remains the same with every trade.

What is Uniswap? A guide to how Uniswap (UNI) works (6)

It’s this constant k that helps determine the price of the tokens. Here’s an example to understand this better.

Let’s say Alice deposits 10 ETH and 100 DAI into a liquidity pool. The k value is 10*100 = 1000 and according to the constant product formula, the pool should maintain this value regardless of whether tokens are withdrawn or added to the pool.

Using Uniswap for arbitrage

One unique way to leverage Uniswap is through arbitrage.

Arbitrage in crypto refers to taking advantage of price differences for the same digital asset on multiple exchanges. Uniswap's liquidity pools can be used to identify arbitrage opportunities, allowing traders to exploit these differences to make a profit by buying low on one exchange and selling high on another.

For the Uniswap protocol itself, however, the practice of arbitrage serves a different purpose: It actually helps Uniswap adjust token prices to match the market prices on other exchanges.

Benefits of using Uniswap

Uniswap offers several advantages that have contributed to its popularity over other decentralized exchanges.

Lower fees

Uniswap's fee structure is often more competitive than other exchanges. Users pay a small fee for each trade, which is then shared with liquidity providers. This makes it an attractive option for traders looking to minimize transaction costs, and incentivizes users to contribute to the platform.

Global accessibility

Uniswap is accessible to anyone with an internet connection, and it operates 24/7. This helps break down barriers and allows users from around the world to participate in decentralized finance (DeFi).

No centralized intermediary

Uniswap operates as a decentralized exchange, meaning there's no central authority or intermediary controlling the platform. This mitigates the risk of third-party manipulation, helps prevent centralized hacks, and ensures that users have full control over their funds.

Real-world financial tools

Uniswap has played a significant role in DeFi applications (dApps), such as decentralized lending, where users can borrow and lend digital assets without the need for a central entity. These applications often rely on Uniswap's liquidity pools to ensure that assets can be efficiently traded.

Uniswap risks

While Uniswap offers many benefits, it's essential to be aware of the potential risks associated with using the platform.

Smart contract vulnerabilities

As with any decentralized application, Uniswap is built on smart contracts. While these contracts are generally secure, there's always a risk of vulnerabilities or exploits. Although Uniswap has a strong track record for security, no system is entirely immune to vulnerabilities.

Impermanent loss

Liquidity providers are exposed to impermanent loss, a temporary loss of value that can occur when the price of the two tokens in a pool diverge. Since cryptocurrency prices can change often, impermanent loss will occur whether token prices go up or down during the time that they are kept in the liquidity pool.

Impermanent loss means that a liquidity provider may end up with fewer tokens than they initially deposited, despite earning passive income via trading fees. This risk is inherent in liquidity provision, and is important to consider for potential liquidity providers.

Market volatility

Cryptocurrency markets can be highly volatile, and this can result in rapid price fluctuations, affecting the value of assets held in liquidity pools.

As with any investment or financial activity, users should conduct thorough research and follow best security practices when using Uniswap or any DeFi platform. This could include using hardware wallets, enabling two-factor authentication, and being wary of phishing and other scam attempts.

The history of Uniswap V1 to Uniswap V3

When Uniswap V1 first launched in November 2018, it used the constant product formula k=x.y still used today, though it only supported trades from ETH to other ERC20 tokens.

For example, if you wanted to trade USDC for DAI, you’d first have to convert USDC to ETH, and use the ETH to buy DAI tokens. This was highly inefficient, so Uniswap launched its second version.

Did you know? MoonPay makes it easy to make direct crypto swap transactions like the ones listed above.

Uniswap V2 did away with the condition that you had to convert your ERC-20 tokens into ETH, and enabled traders to create ERC-20 token pairs. Like Uniswap V1, it also used the k=x.y formula to provide liquidity at all price ranges.

What is Uniswap? A guide to how Uniswap (UNI) works (7)

The main aim of Uniswap V2 was to provide liquidity across all price ranges by creating a constant product market, but this resulted in a large amount of liquidity in the pools being unused. This is the problem that Uniswap V3 seeks to solve.

Instead of providing liquidity across the entire price range, Uniswap V3 provides concentrated liquidity across smaller price ranges, called positions. These positions act as constant product pools and maintain just enough reserves to support trading within that range.

What is Uniswap? A guide to how Uniswap (UNI) works (8)

The smaller reserves within the pools are called virtual reserves, and LPs can create as many of them as they want. By doing so, they are creating different positions across different price ranges to improve the usage of liquidity.

What is Uniswap? A guide to how Uniswap (UNI) works (9)

In other words, Uniswap has broken itself down into smaller pools with reserves distributed across the most popular trading price ranges, instead of being a giant token pool with one large reserve.

Uniswap competitors and alternatives

While Uniswap is a pioneer in the automated market maker (AMM) space, it's not the only decentralized exchange (DEX) available. Here are several DEX alternatives:

SushiSwap

What is Uniswap? A guide to how Uniswap (UNI) works (10)

SushiSwap is a decentralized exchange (DEX) that began as a Uniswap fork but has since developed its own ecosystem. SushiSwap introduced the concepts of yield farming and staking, allowing users to earn additional tokens as passive income by providing liquidity.

PancakeSwap

What is Uniswap? A guide to how Uniswap (UNI) works (11)

PancakeSwap operates on the Binance Smart Chain, offering an alternative to Ethereum-based DEX platforms. It's known for its low transaction fees and has a similar AMM model to Uniswap.

1inch

What is Uniswap? A guide to how Uniswap (UNI) works (12)

1inch is a DEX aggregator that sources liquidity from multiple decentralized exchanges, including Uniswap. It aims to provide users with the best available prices by routing trades through various exchanges.

FAQs about Uniswap

1. Is Uniswap safe?

Uniswap is decentralized and therefore not prone to hacker attacks that can steal users’ funds on centralized exchanges (CEXs). Plus, it’s built on Ethereum, so it has the same security properties as the leading Proof of Stake blockchain.

However, no exchange can offer complete security so make sure to do your own research before using any exchange.

2. What can Uniswap (UNI) tokens be used for?

The Uniswap (UNI) token is a governance token that can be used to create and vote on proposals to improve the protocol.

You can also trade it for other cryptocurrencies and sell it to another address to transfer your ownership and governance rights.

3. How to use Uniswap?

To get started with Uniswap, you’ll need to download an Ethereum-based wallet like MetaMask.

Once you’ve downloaded and set up your non-custodial wallet, go to the Uniswap exchange and follow the instructions.

Not sure how to choose a wallet? Read our helpful guide

4. How to claim UNI tokens?

Before you claim your UNI tokens, ensure that you connect the wallet that you previously used on Uniswap. If you’re eligible to claim Uniswap tokens, you’ll see a popup in the top right corner of your Uniswap app.

To claim the tokens and approve the transaction, choose the correct gas fees and click “Claim your tokens” to approve the transaction.

Recommended reading: Ethereum gas fees

5. How is the UNI token price determined?

The price of the UNI token, like most cryptocurrencies, is determined by supply and demand in the open crypto market. Traders and investors can swap UNI tokens on Uniswap and other exchanges, influencing the UNI token price.

The future of Uniswap

Uniswap has established itself as a leading decentralized exchange, offering numerous benefits such as its automated liquidity protocol, lower fees, liquidity pools, and global accessibility. Its governance model allows anyone to actively participate in shaping the platform's future via UNI tokens.

However, participating in DeFi is not without its risks, and users should exercise caution and conduct due diligence when using the platform.

Uniswap continues to evolve, with many developments and upgrades planned for the future. These include improvements to the user interface, governance enhancements, and expansion to Layer-2 scaling solutions to reduce transaction fees and increase efficiency.

How to buy UNI tokens

You can buy UNI via MoonPay or through any of our partner wallet applications with a credit card, bank transfer, Apple Pay, Google Pay, and many other payment methods.

Just enter the amount of Uniswap (UNI) you wish to purchase and follow the steps to complete your order.

What is Uniswap? A guide to how Uniswap (UNI) works (13)

Written byCorey Barchat

You might also like

Why does Bitcoin have value? What makes BTC valuableIf crypto tokens like Bitcoin are completely digital, what gives them real-world value? Discover here, as we explore the main factors driving demand.
What is the Ethereum Virtual Machine (EVM)?The Ethereum Virtual Machine helps to power the Ethereum network. But what is it and how does it work? Find out in this handy guide.
What are blockchain nodes and how do they work?Learn what a blockchain node is, the different types, and their crucial role in securing, validating, and maintaining decentralized networks.
What are utility tokens and how do they work?Learn what makes utility tokens stand out from other cryptocurrencies, and how they function within different types of blockchain projects.
Permissioned vs. Permissionless Blockchain: A comprehensive guideLearn how permissioned vs permissionless blockchains differ from each other, and find out which one suits the needs of various industries.
What are stablecoins and how do they work?Discover what stablecoins are, how they work, their types, benefits, uses, and risks in this comprehensive guide to stable digital assets.
What is Uniswap? A guide to how Uniswap (UNI) works (2024)

FAQs

What is Uniswap? A guide to how Uniswap (UNI) works? ›

Uniswap is a decentralized exchange project consisting of a set of smart contracts running on the Ethereum blockchain. Uniswap incentivizes its users to maintain the liquidity of the exchange, providing portions of the transaction fees and newly minted UNI tokens to those who participate.

What is Uniswap and how does it work? ›

Uniswap is a decentralized protocol that acts as an automated market maker for peer-to-peer cryptocurrency transactions. The Uniswap platform enables users to provide liquidity and swap cryptocurrencies. Its own cryptocurrency, UNI, is used for protocol governance.

How do you use Uniswap step by step? ›

To swap tokens on Uniswap follow these steps:
  1. Open Uniswap web app and connect your wallet. ...
  2. Search for and select the token you wish to swap. ...
  3. Now you have to select the token you want to swap for. ...
  4. Search for and select the token you wish to swap for.
Apr 28, 2024

What is the Uniswap equation? ›

This formula, most simply expressed as x * y = k , states that trades must not change the product ( k ) of a pair's reserve balances ( x and y ). Because k remains unchanged from the reference frame of a trade, it is often referred to as the invariant.

How does Uniswap pool work? ›

Uniswap liquidity pools

These pools are created by users called liquidity providers who contribute both of the tokens in trading pairs, typically in equal value. Liquidity pools enable users to exchange tokens seamlessly, and reward providers with transaction fees for their participation.

How do I get money from Uniswap? ›

Liquidity withdrawals are done directly from Uniswap, by following the steps below:
  1. Make sure to have your web3 connected to tag along.
  2. Go to the Uniswap page and select Pool.
  3. The interface will display all your positions in Liquidity Pool.
  4. Select which position you wish to withdraw from.
  5. Click Remove.

Do I need a wallet for Uniswap? ›

What is a Uniswap (UNI) Wallet? Your UNI wallet is your proof of ownership. You need a UNI wallet to access, buy and trade your UNI coins.

Why can't I sell a coin on Uniswap? ›

This is most likely due to a scam token, where the token owner has maliciously disabled the transfer function in a way that allows users to buy the token, but not sell them.

How do I connect Uniswap to my wallet? ›

To connect your wallet to Uniswap:

Select the “Connect” icon. Select the wallet you would like to connect. If your wallet is not listed, select WalletConnect to choose from the list of supported wallets. If your wallet is a browser extension or desktop app, select “View All” to find your wallet.

Is it safe to keep coins in Uniswap? ›

Safe: Funds are never transferred to any third party or generally subject to counterparty risk (i.e. trusting your assets with a custodian) because both parties are trading directly from their own wallets. Global and permissionless: There is no concept of borders, or restrictions on who can trade.

How much is 1 Uniswap worth? ›

Uniswap Price Summaries

Uniswap's price today is US$6.58, with a 24-hour trading volume of $83.13 M.

What algorithm does Uniswap use? ›

In the context of Uniswap v1, the type of algorithm that is used in the AMM is called the constant product market maker (CPMM), and the tokens contained in the liquidity pools were only ETH - ERC-20 token pairs.

What currency does Uniswap use? ›

UNI is an Ethereum token that powers Uniswap, an exchange that allows users to easily trade different Ethereum assets in a decentralised manner, and uses an automated market making system rather than a traditional order book.

How do you mine liquidity on Uniswap? ›

To add liquidity on Uniswap V3:
  1. Open the Uniswap web app. ...
  2. Select “New position”.
  3. Select the token drop-down.
  4. Select the token you want to add liquidity for. ...
  5. After selecting the first token, now select the second token. ...
  6. Select the second token you want to add liquidity for.
  7. Select the fee tier for your pool.
Feb 27, 2024

Can anyone create a pool on Uniswap? ›

You can create and deploy your own pools, consisting of the pairs you pick and the pool fee you choose. After creating a pool, it needs liquidity so traders can use it. Anyone can deposit their funds into a pool and become a liquidity provider (LP).

How much does Uniswap charge for trades? ›

There is a 0.3% fee for swapping tokens.

Can US citizens use Uniswap? ›

Yes, US citizens can use Uniswap to trade digital assets, provide liquidity, or create new markets to exchange digital assets for fiat currencies, with partnerships with providers like MoonPay and availability on platforms like Coinbase.

Can you make money with Uniswap? ›

Uniswap incentivizes users to add liquidity to trading pools by rewarding providers with the fees generated when other users trade with those pools.

What is the disadvantage of Uniswap? ›

Cons of Uniswap

One of the main drawbacks of being a liquidity provider on Uniswap is the risk of impermanent loss. Impermanent loss occurs when the price of the assets in a liquidity pool diverge, resulting in lower returns for liquidity providers compared to holding the assets themselves.

Does Uniswap report to IRS? ›

This does not exempt users from their tax obligations. Transactions on Uniswap are recorded on the blockchain. So while Uniswap doesn't report to the IRS, the transparency of blockchain technology means anyone, including tax authorities, can potentially trace and analyze transaction histories.

Top Articles
Not on my porch: How to avoid package theft
How to see word count on Google Docs: Check progress on your writing project in real time.
Golden Abyss - Chapter 5 - Lunar_Angel
Amc Near My Location
Jonathon Kinchen Net Worth
St Petersburg Craigslist Pets
Fototour verlassener Fliegerhorst Schönwald [Lost Place Brandenburg]
Emmalangevin Fanhouse Leak
DIN 41612 - FCI - PDF Catalogs | Technical Documentation
3472542504
Zürich Stadion Letzigrund detailed interactive seating plan with seat & row numbers | Sitzplan Saalplan with Sitzplatz & Reihen Nummerierung
Los Angeles Craigs List
Premier Reward Token Rs3
Slope Tyrones Unblocked Games
Golden Abyss - Chapter 5 - Lunar_Angel
Talbots.dayforce.com
Exterior insulation details for a laminated timber gothic arch cabin - GreenBuildingAdvisor
Panic! At The Disco - Spotify Top Songs
Atdhe Net
Pecos Valley Sunland Park Menu
Amazing Lash Studio Casa Linda
South Bend Weather Underground
480-467-2273
The Ultimate Guide to Obtaining Bark in Conan Exiles: Tips and Tricks for the Best Results
Culver's Hartland Flavor Of The Day
Puerto Rico Pictures and Facts
Moxfield Deck Builder
Rise Meadville Reviews
Vip Lounge Odu
Covalen hiring Ai Annotator - Dutch , Finnish, Japanese , Polish , Swedish in Dublin, County Dublin, Ireland | LinkedIn
Why The Boogeyman Is Rated PG-13
The Land Book 9 Release Date 2023
Myanswers Com Abc Resources
Trizzle Aarp
Registrar Lls
Achieving and Maintaining 10% Body Fat
The best specialist spirits store | Spirituosengalerie Stuttgart
Weather In Allentown-Bethlehem-Easton Metropolitan Area 10 Days
Hovia reveals top 4 feel-good wallpaper trends for 2024
Hkx File Compatibility Check Skyrim/Sse
Wilson Tire And Auto Service Gambrills Photos
Memberweb Bw
Senior Houses For Sale Near Me
Caphras Calculator
New Starfield Deep-Dive Reveals How Shattered Space DLC Will Finally Fix The Game's Biggest Combat Flaw
Jackerman Mothers Warmth Part 3
Argus Leader Obits Today
Understanding & Applying Carroll's Pyramid of Corporate Social Responsibility
A Snowy Day In Oakland Showtimes Near Maya Pittsburg Cinemas
Peugeot-dealer Hedin Automotive: alles onder één dak | Hedin
Service Changes and Self-Service Options
Latest Posts
Article information

Author: Nicola Considine CPA

Last Updated:

Views: 6568

Rating: 4.9 / 5 (69 voted)

Reviews: 84% of readers found this page helpful

Author information

Name: Nicola Considine CPA

Birthday: 1993-02-26

Address: 3809 Clinton Inlet, East Aleisha, UT 46318-2392

Phone: +2681424145499

Job: Government Technician

Hobby: Calligraphy, Lego building, Worldbuilding, Shooting, Bird watching, Shopping, Cooking

Introduction: My name is Nicola Considine CPA, I am a determined, witty, powerful, brainy, open, smiling, proud person who loves writing and wants to share my knowledge and understanding with you.