---
title: "Comment by José Pablo Ramírez Vargas on \"Access Token, Refresh token, and Refresh Token Rotation\" | Hashnode"
description: "Don&#39;t save tokens in the database. It is the same as saving a user&#39;s password in clear text."
url: "https://hashnode.com/posts/access-token-refresh-token-and-refresh-token-rotation/62f0303cdfc2b1556588467e/comment/639572779fa713176ab9d979"
---

[Discussion](https://hashnode.com/posts/access-token-refresh-token-and-refresh-token-rotation/62f0303cdfc2b1556588467e)

Comment [Access Token, Refresh token, and Refresh Token Rotation](https://hashnode.com/posts/access-token-refresh-token-and-refresh-token-rotation/62f0303cdfc2b1556588467e)

[José Pablo Ramírez Vargas](https://hashnode.com/@webJose)

[Dec 11, 2022](https://hashnode.com/posts/access-token-refresh-token-and-refresh-token-rotation/62f0303cdfc2b1556588467e/comment/639572779fa713176ab9d979)

Don't save tokens in the database. It is the same as saving a user's password in clear text.

[mathew adetunji](https://hashnode.com/@maytheu)

[Dec 12, 2022](https://hashnode.com/posts/access-token-refresh-token-and-refresh-token-rotation/62f0303cdfc2b1556588467e/comment/639572779fa713176ab9d979#reply-6397330815750808b26a0716)

Thanks for the comment and for pointing that out, how should token be handled without using third-party solutions?

[José Pablo Ramírez Vargas](https://hashnode.com/@webJose)

[Dec 12, 2022](https://hashnode.com/posts/access-token-refresh-token-and-refresh-token-rotation/62f0303cdfc2b1556588467e/comment/639572779fa713176ab9d979#reply-639747d215750808b26a0bc1)

[mathew adetunji](https://hashnode.com/@maytheu) Hi. Generally speaking, the safest way to invalidate tokens is by demanding a specific minimum `issued at` time.

I explain the logic behind this invalidation method [here](https://webjose.hashnode.dev/invalidating-json-web-tokens-jwt-the-right-way). This can be refined to apply to refresh tokens only, if you wish, or invalidating per token type.

You'll also see **alternative 1** that tells you to key the tokens. Then you can more safely save token keys, not tokens. I discourage this path, though, because of the extra administrative work around maintaining the keys.
