Bancor is an innovative protocol that allows for the creation of decentralized liquidity networks on Ethereum and other smart contract blockchains. Launched in 2017, Bancor utilizes innovative token bonding curves to enable continuous liquidity for tokens, without needing external counterparties like buyers and sellers.
Bancor aims to solve the liquidity challenges faced by long-tail tokens by introducing a new “long-tail” model for liquidity. The protocol allows any project to create a liquid token using Bancor’s smart contracts, with no need for external liquidity providers. Bancor tokens hold their value better and have lower slippage than tokens on centralized exchanges.
How Bancor Works
The core of the Bancor protocol is the smart token, which contains one or more connectors to other tokens. These connectors hold balances of the connected tokens, allowing the smart token to be converted to any of its connectors at algorithmically calculated prices.
When a Bancor token is purchased or sold, the smart contract automatically buys or sells the connected tokens to counteract the transaction. This keeps the token’s price balanced around its calculated equilibrium point.
For example, a BNT token (Bancor’s network token) could contain 50% ETH and 50% DAI as connectors. When BNT is purchased with ETH, the contract sells BNT and buys ETH and DAI to cover the transaction. The opposite occurs when BNT is sold.
This allows BNT to be seamlessly convertible to any of its connected tokens via the contract, with the price updated dynamically based on the changing connector balances.
Bancor Token Converter
At the core of every Bancor token is the Token Converter, an on-chain liquidity provider that replaces traditional order books. The converter holds balances of its connected tokens and uses these to buy and sell the Bancor token via an automated formula.
The token converter recalculates a new price for the Bancor token after each conversion using its connector balances. The formula calculates the token’s equilibrium by weighting the relative connector balances.
When a Bancor token is bought or sold, the converter adjusts its connector balances to account for the change in supply of the Bancor token. This keeps the price gravitating towards the calculated equilibrium point.
Bancor Network Token (BNT)
BNT is the network token which connects all tokens in the Bancor network. BNT provides the following functions:
- Connector Token: BNT is a connector for all convertible tokens in the network, allowing any two tokens to be converted via their BNT connectors.
- Network Staking: BNT allows users to stake and earn a share of conversion fees from the network’s activity.
- Governance: BNT grants voting weight for governing and developing the network.
- Liquidity Backing: The Bancor Foundation uses its BNT to initially fund and “seed” liquidity to new tokens in the network.
Benefits of Using Bancor
The Bancor protocol provides several key advantages over centralized and traditional decentralized exchanges:
No Order Books or Buyers Needed
Liquidity is automated via smart contracts rather than relying on order books with buyers and sellers. Any project can create a token with built-in liquidity regardless of trade volume or exchange listings.
No Spread or Slippage
Tokens have minimal price slippage as conversion prices are calculated algorithmically based on the token’s connector balances. There are no order book bid-ask spreads.
Constant Liquidity
Smart tokens are always convertible via their connectors. Tokens do not need to rely on variable liquidity from buyers and sellers.
No Centralized Price Oracles
Conversion prices are calculated on-chain based on connector balances, with no need for off-chain price oracles. This enhances decentralization.
Lower Fees
There are no platform fees, only gas costs for on-chain transactions. Converter fees, if any, are set by the token creator.
Built-In Price Stability
The token connector balances allow the smart token price to reliably maintain its pegged equilibrium price.
How to Use Bancor
Using Bancor to convert between tokens simply requires interacting with the token’s smart contract. Here is the basic process:
- Obtain the token you want to convert from (Token A)
- Access the token contract for Token A and call the “convert” function
- Input the amount of Token A to convert and the address of the token you want to convert to (Token B)
- The contract will calculate the amount of Token B you should receive based on the current connector balances and conversion formula.
- The contract will then automatically convert Token A to Token B by buying and selling its connector token balances as needed.
- You will receive Token B directly to your wallet after paying gas fees.
The conversion takes place entirely on-chain via the token’s smart contract. At no point do you need to rely on orders from buyers or sellers, as the connector balances provide the liquidity.
Bancor v2.1 Update
In March 2020, Bancor released a major protocol upgrade called Bancor v2.1. This introduced several key improvements:
- Single-Sided AMM: Converters allow single-sided exposure and increase capital efficiency by 50-150% compared to v2.0
- Flexible Fees: Creators can customize converter fees, anywhere from 0% to 30%, replacing the 0.1% fixed fee.
- Elastic Supply Tokens: Tokens can have elastic supplies with no fixed cap if desired.
- BNT as Primary Reserve: BNT is the default reserve token with lower conversion fees, while still allowing other tokens as reserves.
- Chain Agnostic: The protocol can leverage different blockchains via bridges, starting with EOS.
These upgrades create a more flexible and efficient AMM model while keeping user experience seamless. Bancor aims to become the standard for on-chain liquidity provision.
Creating a Bancor Token
To create your own smart token with built-in conversion, you simply need to define your token and choose which other tokens you want as connectors. Here is the basic process:
- Set up a standard ERC-20 token contract for your new token.
- Deploy a Bancor Converter contract and set your desired conversion fee percentage.
- Whitelist connector tokens by defining the token addresses and weights. Higher weights allocate more of the connector balance.
- Fund the converter with balances of the whitelisted tokens. These will become the converter’s connector balances.
- Link your token contract to the Bancor Converter contract.
Once linked, your token will use the converter to facilitate conversions between your token and its connectors. The connector balances provide the liquidity needed for continuous on-chain conversion.
Integrating with Bancor
The open source Bancor protocol allows any project to integrate with the network for enhanced liquidity. Here are some ways to leverage Bancor:
Create a Convertible Token: Any ERC20 token can integrate a token converter to become a smart Bancor token with automated conversions.
Add a BNT Connector: Having BNT as a connector gives access to the entire Bancor network for increased liquidity.
Stake BNT: Staking BNT grants a share of network fees and voting rights for governance.
Use vBNT: projects can hold convertible vBNT instead of regular BNT to share in staking benefits.
Contribute to Liquidity Pools: Users can fund or withdraw from public converter pools to help contribute liquidity.
List on Bancor Network: Token teams can apply to be listed on the Bancor Network dApp for increased visibility.
Bridge to EOS: Projects can deploy converters across multiple blockchains, currently Ethereum and EOS.
Token Grants: The Bancor Grants Program provides funding and support for quality tokens integrating their protocol.
BancorDAO: Decentralized Governance
Bancor utilizes a DAO (decentralized autonomous organization) structure to give BNT holders governance over the network and protocol.
BNT allows holders to vote on improvement proposals and key parameters such as:
- Suggesting additional connectors for the BNT converter
- Adjusting BNT staking rewards
- Changing platform fees
- Upgrading smart contracts
- Adding new features and integrations
Using a DAO structure lets the community govern Bancor in a transparent and democratic manner. BNT stakers can actively shape the future evolution of the ecosystem.
Bancor v3 – The Latest Protocol Upgrade
In September 2022, Bancor launched its v3 upgrade focused on maximizing capital efficiency and minimizing slippage. Key highlights include:
- Dynamic Holders + Fixers: Liquidity is split between dynamic “holders” and concentrated “fixers” with lower slippage risk.
- Weighted Oracles: Prices draw on-chain data from Uniswap, Curve and more for accuracy.
- Flexible Tokens: Any token type can integrate (elastic/capped, rebasing, meta tokens).
- Funding Rate: Positive funding incentivizes liquidity when long/short imbalance occurs.
- Impermanent Loss Protection: Partial loss protection allows safer yield for liquidity providers.
These features create a more efficient and protected AMM model, while retaining the core focus on continuous liquidity and minimizing slippage.
Conclusion
Bancor offers a novel solution to the liquidity crunch facing long-tail digital assets, using smart contracts to automate pricing and eliminate order books. User-generated tokens can hold their value better and convert seamlessly thanks to built-in connector balances.
The protocol continues to expand with added features like flexible fees, gas-free conversions, bridges to EOS, and a robust DAO governance system. The latest v3 upgrade optimizes efficiency and capital usage while minimizing slippage.
By pioneering decentralized on-chain liquidity provision, Bancor aims to become the standard for automatically convertible tokens, allowing any project to create liquid smart tokens on Ethereum and beyond. The project shows the transformative potential of DeFi for inventing real-world solutions previously inconceivable in finance.