# Add ERC20 permit() function

**URL:** <https://forum.openzeppelin.com/t/add-erc20-permit-function/2706>\
**Category:** General\
**Created:** [April 22, 2020, 2:32am UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706 "2020-04-22T02:32:36Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [April 22, 2020, 2:32am UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706/1 "2020-04-22T02:32:36Z")

</div>

Discussion for adding `permit` to ERC20:

> <https://github.com/OpenZeppelin/openzeppelin-contracts/issues/2206>
>
> There's been some discussion about an ERC20 extension with the \`permit\` function…, popularized by MakerDAO's Dai token (see the code \[here\](https://github.com/makerdao/dss/blob/44330065999621834b08de1edf3b962f6bbd74c6/src/dai.sol#L118-L140)). 
> 
> This recently became even more relevant in light of hacks revolving ERC777 and reentrancy, since \`permit\` could help solve some of the UX issues that drive people to using ERC777 improperly. It looks like \[a proper ERC might be in the works\](https://twitter.com/MartinLundfall/status/1251880329264201730): we should make sure we're compliant if that ends up happening. In all likelihood the spec will be identical to the Dai code, however.
> 
> \[Link to EIP-2612\](https://eips.ethereum.org/EIPS/eip-2612)

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [April 24, 2020, 11:28pm UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706/2 "2020-04-24T23:28:49Z")

</div>

> <https://github.com/ethereum/EIPs/issues/2613>
>
> This is a place for discussing #2612, which proposes an additional method permit for making approvals by way of signed messages...

---

<div class="post-metadata">

**Author:** ![Ro5s](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/ro5s/32/601_2.png) [@Ro5s](https://forum.openzeppelin.com/u/Ro5s)\
**Post date:** [October 11, 2020, 7:55pm UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706/3 "2020-10-11T19:55:57Z")

</div>

Some devs are working on [permit() implementation for wETH](https://github.com/wETH-v2/wETH-v2/blob/main/contracts/WETH10.sol) based on [@albertocuestacanada work](https://github.com/albertocuestacanada/ERC20Permit/blob/master/contracts/ERC20Permit.sol) from [OZ reference](https://github.com/OpenZeppelin/openzeppelin-contracts/blob/53516bc555a454862470e7860a9b5254db4d00f5/contracts/token/ERC20/ERC20Permit.sol). Would be fantastic to get extra eyes and think through pushing a std. permit() reference in OZ library. 🏌️‍♂️🙏 Onward to crush gas costs!

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [October 11, 2020, 11:06pm UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706/4 "2020-10-11T23:06:04Z")

</div>

Hi @Ro5s,

It would be great to have a standard permit for ERC-20.

EIP-3009 is also a possibility to consider:

> **[EIP-3009: Transfer With Authorization](https://eips.ethereum.org/EIPS/eip-3009)**
>
> Details on Ethereum Improvement Proposal 3009 (EIP-3009): Transfer With Authorization

> <https://twitter.com/smpalladino/status/1313526048143945729?s=20>

---

<div class="post-metadata">

**Author:** ![frangio](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/frangio/32/15251_2.png) [@frangio](https://forum.openzeppelin.com/u/frangio)\
**Post date:** [October 13, 2020, 2:36pm UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706/5 "2020-10-13T14:36:21Z")

</div>

We want to provide `permit` in OZ Contracts, but the EIP remains in Draft status and we have a policy of not publishing Drafts because they could need breaking changes in the future.

Do you know if anyone is working on moving the EIP to Final?

**Edit:** `ERC20Permit` is now a part of OpenZeppelin Contract.

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [April 28, 2021, 2:48am UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706/6 "2021-04-28T02:48:12Z")

</div>

A post was split to a new topic: [Why is ERC20Permit better than approve/transferFrom?](https://forum.openzeppelin.com/t/why-is-erc20permit-better-than-approve-transferfrom/7478)

---

<div class="post-metadata">

**Author:** ![frangio](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/frangio/32/15251_2.png) [@frangio](https://forum.openzeppelin.com/u/frangio)\
**Post date:** [May 20, 2021, 7:29pm UTC](https://forum.openzeppelin.com/t/add-erc20-permit-function/2706/8 "2021-05-20T19:29:44Z")

</div>

A post was split to a new topic: [ERC20Permit + SignatureChecker](https://forum.openzeppelin.com/t/erc20permit-signaturechecker/8839)
