CEX and DEX
10 minutes
AdvancedDecentralized exchanges (DEX) have gained popularity not only due to the hype around decentralized finance products (DeFi). But the hype surrounding the decentralized exchange Uniswap has sparked debates again about the pros and cons of decentralized and centralized exchanges (CEX).
Many crypto enthusiasts believe that the market share of decentralized exchanges could significantly increase in the future. And many of the well-known cryptocurrency exchanges are also currently working on a decentralized version of their trading platforms.
History of cryptocurrency trading on the exchange
Before we shed light on the technical differences between CEX and DEX, let's take a look back in time. In fact, trading in digital currencies and tokens in the way we know them today is only a few years old. Much has happened since the "genesis block" of Bitcoin (BTC) was mined in early 2009, and Satoshi Nakamoto sent the first transaction to Hal Finney. In 2009, New Liberty Standard set the price of 1 BTC as a central authority. A year later, the first Bitcoin exchange, Mt.Gox, opened its doors. In 2014, Mt.Gox ended its operations with one of the most serious cryptocurrency thefts to date. Hackers stole 744,000 BTC, and the exchange went bankrupt.
Meanwhile, Coinbase gained prominence and is now one of the largest exchanges in the world. The centralized exchange from America captured the market and offered a simple trading platform with an integrated wallet and professional exchange.
Subsequently, as interest in digital currencies grew, other exchanges opened their doors. Most of these exchanges were centralized, and with Binance, Bitmax, Bitfinex, and OKEx, well-known representatives quickly rose to the top. For a long time, bypassing these trading platforms was impossible. It was only with the success of decentralized finance applications that decentralized exchanges such as Uniswap, Sushiswap, and Compound came into focus.
CEX and DEX - what's the difference?
As shown earlier, decentralized and centralized exchanges have been operating in parallel for many years. While the popularity of DEXs did not reach the level of their centralized counterparts for a long time, they play an important role in the history of digital currencies. And especially during the DeFi boom, the Uniswap DEX was even able to surpass the daily trading volume of the crypto giant Coinbase. But why are there two different types of exchanges and what is the difference?
CEX - centralized exchanges
A centralized exchange (CEX), such as Binance, Kraken, or OKEx, has its own order book where each order is registered and confirmed. To ensure correctness, data is exchanged internally through dedicated servers and undergoes centralized security processes. Usually, CEXs operate under the supervision of regulatory bodies and have an extensive built-in "know your customer" (KYC) policy.
At the same time, centralized exchanges actively combat fraudsters in accordance with the current legislation on anti-money laundering. Novices, in particular, use this type of exchange because the centralized structure allows for the use of a convenient platform that makes purchasing and managing digital currencies particularly simple.
The volume of orders and transactions is usually significantly higher than on DEX. This is also due to the fact that network nodes do not need to be updated in real-time. As a result, trading speed is very high. However, the simplicity of the platform described earlier requires that the private keys of integrated wallets remain on the exchange. Thus, access to crypto assets is directly linked to the user's account information. If a fraudster gains access to the account information through phishing or hacking, they will have direct access to the stored crypto assets.
CEX stands for commercial exchange. To create a good user experience, these companies often offer a wide range of support services. They also allow buying cryptocurrencies for fiat currency and usually have a wide range of trading pairs. Centralized exchanges have fixed fees that are charged when trading. Conceptually, a crypto exchange works on the same principle as any other exchange. The algorithm for selecting partners regulates supply and demand, and user orders are stored in the order book.
DEX - decentralized exchange
Decentralized exchanges (DEX) also offer the basic functions of CEX, such as order books or Automated Market Makers (AMM), a trading platform, matching system, and security features. The difference from centralized exchanges is that all these functions are decentralized. To this end, DEX is not based on internal servers and its own IT infrastructure, but operates as a decentralized application (dApp) on the blockchain. Essentially, it is important to distinguish between two types of decentralized exchanges: currency-oriented and currency-neutral DEX.
The first ones are often based on the Ethereum platform and use ether (ETH) as the central medium. In addition, other blockchains can also be considered as the infrastructure basis, but Ethereum has the largest market share here. Therefore, the latter ones are not based on a specific ecosystem and do not depend on the transfer currency. So-called atomic swaps allow for the quick exchange of cryptocurrencies located in different blockchains. The exchange is regulated by smart contracts, in which each participating party contributes assets intended for exchange.
Users of decentralized exchanges, such as Uniswap, Bisq, or GDEX, mainly use them for two characteristics: anonymity and high security. DEXs are anonymous because trading on them requires almost no user data. Often, users only need a public address to be able to trade on a decentralized exchange.
There are no third parties (government or financial regulators) controlling or setting rules for the exchange as a decentralized application. Another reason for its success is the high level of security. While CEX users do not control their private keys, DEX does not offer a built-in hot wallet, and the private keys remain with the users.
Advantages and disadvantages of DEX and CEX
As previously made clear, centralized and decentralized exchanges differ fundamentally from each other. This difference ensures that both types of exchanges have certain advantages and disadvantages. Below, we will examine the corresponding differences and highlight the main positive and negative characteristics.
DEX Advantages:
A decentralized exchange is free from government requirements, rules, or monitoring. Users interact with each other directly in trading, and there is no involvement of a third party in the exchange. Each user has full access to their private keys and therefore their crypto assets.
Anonymity is certainly one of the main reasons for trading on DEX. There is no authentication procedure, no KYC, and no uploading of personal documents to servers abroad. Usually, a personal address in the relevant blockchain is sufficient to start trading. There is no exchange of personal data between the exchange and any authority.
As a rule, low-cost trading with a large number of trading pairs takes place through a decentralized server network. This significantly minimizes the risk of a hacker attack and makes server downtime virtually impossible. Since DEX is directly on the blockchain, it cannot be targeted by an attack on a central server.
Disadvantages of DEX:
Trading on a decentralized exchange is typically much slower than on centralized alternatives. While this varies from DEX to DEX, each transaction must be verified by miners. When there is a need to quickly respond to changes in market conditions, decentralized exchanges are unlikely to be a suitable trading platform.
High liquidity is the key to the success of an exchange. Exchanges with the highest liquidity are always among the most popular trading platforms. The relatively new concept of decentralized exchanges means that there are significantly fewer traders than on CEX. As a result, liquidity is also significantly lower.
The functionality of DEX is still limited. In addition, the user interface is too confusing for beginners. Limit orders, margin trading, or stop losses are not available to many traders. However, most decentralized exchanges are working to implement features known in CEX.
CEX Advantages:
User interfaces are easy to understand even for beginners, and processes and procedures can be quickly learned. There is easy and straightforward access to relevant trading options. Overall, there is a high level of functionality with various trading options and a wide range of cryptocurrencies.
Thanks to the high volume of trading, CEXs have high liquidity. Exchanges can fulfill payment obligations quickly and easily. The lively activity on centralized trading platforms provides numerous orders to buy and sell, ensuring favorable market trading.
CEXs are based on individual and centralized infrastructure, which provides fast transaction processing in almost real-time. The algorithms of leading exchanges can process thousands of orders per second. Traders can react to market changes without delay.
Major exchanges offer a wide range of digital currencies with countless trading pairs. At the same time, deposits and withdrawals in fiat currency are possible.
Disadvantages of CEX:
Users store their crypto assets on the exchange. Integrated wallets are part of the system and thus are beyond the control of the user. As the ownership of the private keys belongs to the exchange, there is a risk of complete loss if the exchange is compromised (not your keys, not your coins). Such cases are rare, but historically have already occurred with millions in losses.
Controversial downside: centralized exchanges are under the control of regulators, third-party providers, and legal norms. To prevent money laundering, operators are required to collect extensive data about their customers (KYC). This requirement contradicts the main idea of cryptocurrencies.
CEX vs. DEX
The high interest in decentralized finance applications (DeFi) has sparked a frenzy for decentralized exchanges (DEX). This type of trading platform describes an exchange that operates directly on the blockchain without a central controlling body. As one of the most extensive forms of decentralized applications, DEX provides classic cryptocurrency trading. The advantage here is that users can trade immediately without logging in and always have their private keys.
In contrast, there are centralized exchanges (CEX). CEX (examples: Binance, Huobi, Coinbase) are based on a central system that relies on its own infrastructure. Unlike DEX, trading activity is always controlled by a third party. Centralized exchanges boast high liquidity and fast transaction processing. However, in this context, the user is always dependent on the exchange and does not have access to their private keys.
Both types of exchanges have their own advantages and disadvantages. The complete decentralization of DEX aligns with Satoshi Nakamoto's core ideas in developing Bitcoin. However, for many traders, the efficiency of CEX clearly favors the use of centralized exchanges. Nevertheless, many CEXs have recognized the benefits of decentralized exchanges and are currently working on their own versions or integrating DEX features into their systems. Therefore, in the future, a merger of both options on corresponding interfaces is possible.