# Slippage calculation?

**URL:** <https://forum.openzeppelin.com/t/slippage-calculation/18829>\
**Category:** Smart Contracts\
**Created:** [November 13, 2021, 2:02pm UTC](https://forum.openzeppelin.com/t/slippage-calculation/18829 "2021-11-13T14:02:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Antonia\_Sa](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/antonia_sa/32/6221_2.png) [@Antonia\_Sa](https://forum.openzeppelin.com/u/Antonia_Sa)\
**Post date:** [November 13, 2021, 2:02pm UTC](https://forum.openzeppelin.com/t/slippage-calculation/18829/1 "2021-11-13T14:02:26Z")

</div>

Hello

I am currently testing the Uniswap fork DEX V2 and I was wondering how the slippage is calculated.

Let say I have two tokens and the entered amount and I can also pass the minimum amount for buying or selling tokens.

Does it mean if I add for example a slippage of 5% I subtract the 5% of the amount from the entered amount and pass it into minimumAmount?
