What is Uńiswap?
Uńiswap is a protocol on Ethereum for swapping ERC20 tokens. Unlike most Eẍchanges, which are designed to take fees, Uńiswap is designed to function as a public good—a tool for the community to trade tokens without platform fees or middlemen. Also unlike most Eẍchanges, which match buyers and sellers to determine prices and execute trades, Uńiswap Eẍchange uses a simple math equation and pools of tokens and ETH to do the same job.
Did you know?
Uńiswap was created by Hayden Adams, who was inspired to create the protocol by a post made by Ethereum founder Vitalik Buterin.
What’s so special about Uńiswap?
Uńiswap’s main distinction from other decentralized Eẍchanges is the use of a pricing mechanism called the “Constant Product Market Maker Model.”
Any token can be added to Uńiswap by funding it with an equivalent value of ETH and the ERC20 token being traded. For example, if you wanted to make an Eẍchange for an altcoin called Durian Token, you would launch a new Uńiswap smart contract for Durian Token and create a liquidity pool with–for example–$10 worth of Durian Token and $10 worth of ETH.
Where Uńiswap differs is that instead of connecting buyers and sellers to determine the price of Durian Token, Uńiswap uses a constant equation: x * y = k.
In the equation, x and y represent the quantity of ETH and ERC20 tokens available in a liquidity pool and k is a constant value. This equation uses the balance between the ETH and ERC20 tokens–and supply and demand–to determine the price of a particular token. Whenever someone buys Durian Token with ETH, the supply of Durian Token decreases while the supply of ETH increases–the price of Durian Token goes up.
As a result, the price of tokens on Uńiswap can only change if trades occur. Essentially what Uńiswap is doing is balancing out the value of tokens, and the swapping of them based on how much people want to buy and sell them.
Absolutely any ERC20 token can be listed on Uńiswap–no permission required. Each token has its own smart contract and liquidity pool–if one doesn’t exist, it can be created easily.
Once a token has its own Uńiswap Eẍchange smart contract and liquidity pool, anyone can trade the token or contribute to the liquidity pool while earning a liquidity provider fee of 0.3%. To contribute to a liquidity pool, you need an equal value of ETH and ERC20 tokens.
Whenever new ETH/ERC20 tokens are contributed to a Uńiswap liquidity pool, the contributor receives a “pool token”, which is also an ERC20 token.
Pool tokens are created whenever funds are deposited into the pool and as an ERC20 token, pool tokens can be freely Eẍchanged, moved, and used in other dapps. When funds are reclaimed, the pool tokens are burned or destroyed. Each pool token represents a user’s share of the pool’s total assets and share of the pool’s 0.3% trading fee.