Uniswap fees

Fees

Liquidity provider fees

There is a 0.3% fee for swapping tokens. This fee is split by liquidity providers proportional to their contribution to liquidity reserves.

Swapping fees are immediately deposited into liquidity reserves. This increases the value of liquidity tokens, functioning as a payout to all liquidity providers proportional to their share of the pool. Fees are collected by burning liquidity tokens to remove a porportional share of the underlying reserves.

Since fees are added to liquidity pools, the invariant increases at the end of every trade. Within a single transaction, the invariant represents token0_pool / token1_pool at the end of the previous transaction.

There are many community developed tools to determine returns. You can also read more in the docs about how to think about LP returns.

Protocol Fees

At the moment there are no protocol fees. However, it is possible for a 0.05% fee to be turned on in the future.

More information about a potential future protocol fee can be found here.

Protocol Charge Calculation

In the future, it is possible that a protocol-wide charge of 0.05% per trade will take effect. This represents ⅙th (16.6̅%) of the 0.30% fee. The fee is in effect if feeTo is not address(0) ( 0x0000000000000000000000000000000000000000 ), indicating that feeTo is the recipient of the charge.

This amount would not affect the fee paid by traders, but would affect the amount received by liquidity providers.

Rather than calculating this charge on swaps, which would significantly increase gas costs for all users, the charge is instead calculated when liquidity is added or removed. See the whitepaper for more details.


流动性提供者费用

交换代币要收取0.3%的费用。该费用由流动性提供者按其对流动性储备的贡献比例分摊。

交换费用会立即存入流动性储备。这增加了流动性代币的价值,起到了对所有流动性提供者按其在池中的份额比例进行支付的作用。费用是通过燃烧流动性代币来收取的,以去除基础储备的比例份额。

由于费用被添加到流动性池中,因此在每笔交易结束时,不变式会增加。在单笔交易中,不变式代表上一笔交易结束时的池中代币比例。

有很多社区开发的工具可以确定收益。您也可以在文档中阅读更多关于如何考虑LP回报的信息

协议费用

目前没有协议费。但是,将来有可能会收取0.05%的费用。

更多关于未来可能的协议费的信息可以在这里找到。

协议费计算方法

未来,有可能实行每笔交易0.05%的协议收费。这代表了0.30%的费用中的⅙(16.6̅%)。

这个金额不会影响交易者支付的费用,但会影响流动性提供者收到的金额。

该费用不是在swaps上计算,因为这将显著增加所有用户的天然气成本,而是在增加或移除流动性时计算。详见白皮书