In this guide we’ll focus on how you can check if a farm on the Polygon network has a transfer tax function in place. Everytime an investor sends, buys or sells the governance token of a farm that has activated the tranfer tax function, a tax is deducted on top of the transaction fees. By implementing this function, investors are incentivised to HODL the (governance) token in their wallet rather than spending it.
Step 1. Find the MasterChef contract address #
First you need to find the MasterChef contract address of the farm you want to verify. You can usually find this contract address either on the farm’s doc page or on our website rugdoc.io. No luck with finding the MasterChef contract address? Please read this guide.
Step 2. Open the MasterChef contract #
Did you manage to find the MasterChef contract address? Great! The next step is to open the Polygon block explorer and paste the MasterChef contract address in the search bar. In this guide we’ll use Sunrise’s MasterChef.
Step 3. Look for the transfer tax function #
Open the MasterChef contract and select the ‘Contract’ tab. Then click on ‘Code’.
Scroll down to the ‘Contract Source Code’ section. Click inside the code box and press Ctrl+f. To find the transfer tax function, use one of the following keywords: ‘tax’, ‘transfer’ or ‘transfertax’.
You can conclude from the code that, in Sunrise’s case, there’s a 5% transfer tax present for it’s governance token.
contract SUNSET is BEP20 {
// Transfer tax rate in basis points.
uint16 public transferTaxRate = 500;(5%)
You now know how to verify if a farm has a transfer tax function in place. If you want to learn more about DeFi, read our other articles on our wiki as well!