One of the reasons many people are excited about cryptocurrencies and the world of decentralized finance (DeFi) is that, well, it’s decentralized. Intermediaries are cut out of the picture.
However, as cryptocurrency has become increasingly popular, centralized exchanges (CEXs) have popped up. Examples include immensely popular platforms such as Coinbase, Gemini, and Binance.
The problem? Well, these exchanges are centralized. There is a central authority that manages the transactions which is an antithesis to the whole reason cryptocurrencies were created in the first place.
This is where decentralized exchanges like Uniswap come in. With Uniswap or other DEXs, you can contribute to a liquidity pool and set up an exchange for any asset built on the Ethereum blockchain. Let’s take a look at how Uniswap works.
What Is Uniswap?
Rather than being owned by one entity, Uniswap is designed to be a truly decentralized exchange (DEX). In February, it became the first DEX to process more than $100 billion in trading volume. And right now, Uniswap often processes at least $1 billion in trading volume each day.
Uniswap was the creation of Hayden Adams, who was inspired by posts from Ethereum founder Vitalik Buterin about automated market makers (AMMs). After finding out more about Ethereum and how it works, Adams built his own AMM as a decentralized exchange (DEX).
How Do Decentralized Exchanges Work?
A decentralized exchange (DEX) is a flexible trading platform that isn’t controlled by any one person or company. Users retain custody of their private keys. And order pricing, liquidity, and other items are all handled using smart contracts.
The first generation of DEXs used order books, maintained on-chain, to keep records of all buy and sell orders for each supported token. But these decentralized exchanges would often get bogged down when transaction volume was high, leading to slower trade executions. Low liquidity was also a common problem.
Automated market makers (AMMs), or "Swap DEXs," are the next generation of decentralized exchanges. Instead of order books, these DEXs uses liquidity pool protocols to facilitate trades. With a DEX that uses an AMM, users can trade instantly between their wallets.
Uniswap, in particular, works with any ERC-20 token. So it’s possible to introduce your own new token on the exchange with relative ease. Basically, everyone using Uniswap can become a market maker, contributing to a liquidity pool and creating the circumstances to trade any compatible token.
Uniswap Key Features
Like many of the other top decentralized exchanges, Uniswap makes use of smart contracts to execute transactions. In order to participate, you need to have a crypto wallet that’s compatible with Uniswap.
In general, you can use Coinbase Wallet, MetaMask, Portis Wallet, WalletConnect or Fortmatic. Once your wallet is connected, you can begin making transactions.
Before you decide to use Uniswap, you need to make sure you have the right tokens available. Your wallet needs to contain the token you’re trying to exchange and you'll also need to have enough ether to cover the transaction's gas fees.
The main reason Uniswap works with any ERC-20 token is due to the fact that participants are market makers, thanks to an automated liquidity protocol. With this approach, every token on the exchange has a liquidity pool that participants (called liquidity providers) can add to.
While you don’t have to become a liquidity provider, Uniswap offers incentives for you to take this step. A flat fee is charged for trading on Uniswap and that fee is sent to a liquidity reserve. Liquidity providers can receive a portion of those pool trading fees. As long as there’s enough liquidity in the pool, it’s possible to execute a trade at a price that’s set according to a regular algorithm.
Any contribution you make to the liquidity pool is staked, and you receive a token representing your stake. Later, you can use the token as part of your trading fees. Pool tokens can be used on the exchange as well as with dapps. When funds are reclaimed from a liquidity pool, the pool token is burned.
Finally, the latest version of Uniswap offers the ability for liquidity providers to sequester a portion of their contribution to the pool to a specific price range. Another interesting development is the fact that it’s possible to have your position turned into a non-fungible token (NFT). It becomes unique art that exists on Uniswap’s chain.
Token Pricing On Uniswap
One of the most interesting mechanisms associated with Uniswap is the way the token is priced. A set equation is used, which takes into account the ratio of tokens to the liquidity pool. The equation used is x*y=k. K represents a number that doesn’t change. The liquidity pool must remain constant, so the tokens involved have to balance out. So, X represents the first token and the Y represents the second token. Both of the values, when multiplied, must equal K.
One of the benefits of this approach is the fact that a larger liquidity pool can limit price drops due to bigger trades. For example, if you want to trade FEG (a lesser-known deflationary ERC-20 token) for UNI, you could add more FEG to the UNI/FEG liquidity pool. Because the ratio must remain constant, the price of FEG in the pool will drop while the price of UNI rises.
At first glance, it might seem as though it’d be easy to manipulate the system. However, arbitrage is a component of Uniswap token pricing. Traders look for differences between market prices and what’s going on in the liquidity pool. They then place trades based on the imbalances and take their profits while bringing the liquidity pool back in line with ratios that reflect overall market prices.
There are various fee tiers on Uniswap with the latest upgrade, but those tiers operate as flat or fixed fees. That makes it easy to quickly decide which tokens to trade and to understand how much trades will cost.
Because Uniswap works on the Ethereum blockchain, you’ll be subject to gas fees when you complete a transaction. When making your swap, you need to decide whether you want slow, medium or fast. The faster the transaction takes place, the higher your gas fee.
Additionally, some times of day or week can impact your gas fee. The Ethereum blockchain charges its fees based on how many people are using the network at any given time, so your Uniswap transactions will be more expensive if you execute them while more people are using the network.
How To Execute A Uniswap Trade
Moving forward with a Uniswap trade is fairly straightforward. Here are the steps you'll take:
- 1Connect your wallet to the Uniswap platform and login.
- 2Select the token you’re planning to trade in (top field).
- 3Select the token you want to buy (bottom field).
- 4Figure out how much you exchange and enter that amount.
- 5You’ll be able to see an estimate of how much of your desired token you’ll receive in exchange for the token you’re using for the purchase.
- 6Review the purchase, including how much ether you need to pay the gas fee. You can see the final total in U.S. dollars.
- 7As soon as you finish the transaction, your new tokens will appear in your wallet.
There are different services that allow you to transact business in different ways on Uniswap. This includes dapps that are compatible with Uniswap and allow you to add funds to Uniswap quickly and easily, as well as those that allow you to purchase pool tokens, or contribute to liquidity pools using only ether.
Listing Your Own Token On Uniswap
If you’ve created your own token, you can list it on Uniswap and encourage others to buy and sell it. This can be one way to raise capital if you have your own project.
As long as your project is built on the Ethereum blockchain and your token is an ERC-20 token, you should be able to list it on Uniswap.
Here’s how to move forward:
- 1Make sure you have a compatible crypto wallet.
- 2Create your ERC-20 token and make sure the associated contract is on the Ethereum chain. Get the address for the contract.
- 3Send your unique tokens to your crypto wallet.
- 4Once you’ve got your tokens in your wallet, connect to Uniswap.
- 5Use the Pool tab to create a liquidity pool using your token.
- 6Add liquidity by pasting in the address to your token’s contract on the Ethereum mainnet. You do this using the Select a Token button and using the Search Name or Address function.
- 7After you’ve added your token to the Uniswap exchange, you can then select it as part of your pool creation.
- 8Now you can deposit your own unique token, along with how much ether you plan to put in the pool, to create a new liquidity pool.
This is much easier than getting a token listed on a CEX. However, in order for your token to be successful, you need to get people to actually use it and participate in transactions.
On decentralized exchanges like Uniswap, tokens aren't required to pass security protocols before they can be listed. For this reason, they're known for supporting more coins than the typical CEX.
Having more investable assets at your disposal is nice. But you'll also need to carefully do your own research to avoid scam coins if you use Uniswap or any other DEX platform.
For now, the top centralized exchanges are going to be easier and safer to use for beginners. But if privacy is your top priority or you really want to invest in certain altcoins that aren't yet available on most CEXs, using a popular DEX like Uniswap could be the way to go.
Miranda Marquit, MBA, has been covering personal finance, investing and business topics for more than 15 years, and covering crypto topics for more than 10 years. She has contributed to numerous outlets, including NPR, Marketwatch, U.S. News & World Report and HuffPost. She is an avid podcaster, co-hosting the podcast at Money Talks News. Miranda lives in Idaho, where she enjoys spending time with her son playing board games, travel and the outdoors.