OTP Code Bookmarklet Generator

⚠ DANGER ⚠ I TAKE NO RESPONSIBILITY IF YOU GET HACKED. Proceed at your own risk. Your secret key will be stored in plaintext, not only temporarily in the text area on this page, but permanently in the bookmarklet as long as you don't delete it. This site is a static webpage, so it doesn't have access to your secrets, but pasting your MFA secrets here could leave you vulnerable to other avenues of attack like XSS (cross-site scripting). Additionally, bookmarks may be vulnerable to attacks by malicious browser extensions; even if you aren't compromised yet, you may be if some browser extension you have installed is compromised in the future.

This tool generates a single-line, highly compressed JavaScript bookmarklet that calculates a TOTP code and attempts to copy it to the clipboard. If copying fails, the string "copying failed" is copied instead.

First, you will need to create a new OTP key for whatever service you are trying to use. If the service only offers a QR code as the OTP method, you will need to scan the QR code with a QR code reading app or some other method, and then copy the secret key into the below field. Once you've done that, the bookmarklet code should update to reflect your secret key hardcoded into the code.

Next, copy the bookmarklet code by using the "Copy Bookmarklet Code" button beneath it.

After copying the bookmarklet contents below, create a new bookmark by right-clicking the bookmark bar and selecting "Add page...". Set the name to whatever you want, paste the code into the URL field, and hit Save.

Then, whenever you need to log into whatever service requires OTP, you should be able to click the bookmark, which will copy the code directly to your clipboard, and paste the code into the OTP code field.

The key is hardcoded directly into the final generated bookmarklet.

Bookmarklet Code String

Copy the entire string below to the URL field of a new browser bookmark.

Bookmarklet code will appear here.