How your secret is stored

Your secret is locked in your browser before it leaves your device. The server keeps only the locked version, hands it out once and deletes it. The key to unlock it travels only inside the link you send.

The journey of a secret

How a secret travels Your browser encrypts the secret and sends only the encrypted data to the server. The link with the key goes from you to the recipient directly, never through the server. The server hands the encrypted data to the recipient's browser once, which decrypts it with the key from the link. Your browser Encrypts the secret with a new random key 1 encrypted data only Server Stores id, encrypted data and expiry. Never the key. 2 on Reveal, once, then deleted 4 Recipient's browser Decrypts it with the key from the link 5 3 Link with key you send it
The key goes from you to the recipient inside the link. It never passes through the server.
  1. Your browser encrypts the secret

    It creates a new random 256-bit key and a random 96-bit IV for this one secret, and encrypts it with AES-256-GCM using the browser’s built-in Web Crypto API.

  2. The server stores unreadable data

    Only the encrypted data (IV, ciphertext and authentication tag) is uploaded. The server, a Cloudflare Pages Function, picks a random 128-bit id and stores one row: the id, the encrypted data and the expiry time.

  3. You send the link

    The link holds the id and the key after the #. You pass it on yourself, by chat, email or any other way. The key is never sent to the server.

  4. The recipient presses “Reveal”

    Opening the link only shows a “Reveal secret” button; it does not use the secret up. Chat apps and email scanners that open links to build previews therefore cannot destroy it. Pressing Reveal sends a POST request, and the server hands over the encrypted data and deletes it in the same step.

  5. The recipient’s browser decrypts it

    Decryption happens on the recipient’s device, with the key from the link. If the data was changed or damaged, GCM’s authentication tag makes decryption fail instead of showing wrong text. The key is then removed from the address bar.

Anatomy of a link

A one-time link has two parts after the #, separated by a dot.

https://onetimepass.pages.dev/#q3Vb8sKx2LmN0pRtYw7uEa.Zr4nT9vXc2bQ8hLk1mW5sJy0aDfG3pE7uN6iKoH2tRw

An example link, split into its id and key.
Id
Identifies the stored data. Your browser sends it to the server to fetch the encrypted data.
Key
Decrypts the data. It is never sent to the server; it travels only inside the link you send.

Browsers do not include the part after # in requests, and the page’s code sends only the id. The page also sets Referrer-Policy: no-referrer, so the address is not passed to other sites either. The example above is made up.

What the server stores and never sees

Stored, for each secret

  • A random id (128 bits)
  • The encrypted data: IV, ciphertext and authentication tag
  • The expiry time

One row in a Cloudflare D1 database. It is deleted when the secret is revealed, or after it expires (see when the data is deleted).

Never sent to the server

  • Your secret as readable text
  • The key

Not stored by this site

  • Your IP address
  • Accounts
  • Cookies (the secret site sets none; this information site sets Google Analytics cookies only if you accept)
  • Your browser and device details (user agent)
  • Analytics (none on the secret site)

Cloudflare, the host, sees IP addresses and request details as part of serving any website. The secret site (onetimepass.pages.dev) loads no third-party scripts, fonts or trackers on any page. Only this information site, and only if you accept, uses Google Analytics (see privacy).

When the data is deleted

What we cannot protect against

Encryption protects the secret on the server. It cannot fix everything around it.

The password generator

The password and token generator runs entirely in your browser, using crypto.getRandomValues. It uses rejection sampling, so every character is equally likely (no modulo bias). A generated value is never sent anywhere unless you create a link with it, and then only encrypted.

On the command line

The command-line tool uses the same encryption and the same links. It encrypts on your computer, so the server never sees the secret or the key there either.

Questions

Can you read my secret?

No. The server only receives encrypted data. The key that decrypts it is in the part of the link after #, which is never sent to the server.

Why does opening the link not show the secret right away?

Chat apps and email scanners often open links to build previews. If opening the link used the secret up, a preview could destroy it before the recipient sees it. Only pressing “Reveal” uses it.

The recipient says the secret is “no longer available”. What now?

The link was already opened or has expired. If the recipient did not open it, someone else may have. Change the password or token you shared, then send a new link.

Can I check whether my link was opened?

Yes, without using it up. Open your own link and do not press “Reveal”, or run onetime status - and paste the link. If the secret is still waiting, you see the Reveal button; “no longer available” means it was revealed or has expired.

What happens if the link is cut off or changed?

If the link is incomplete, the page says so before anything is used up. If the key was changed, decryption fails instead of showing wrong text. In that case the secret has already been deleted, so ask for a new link.

I lost the link. Can you send it again?

No. The link is the only copy of the key, and the server never had it. Create a new link.

How large can a secret be?

Up to 16 KB. The service stores at most 20,000 secrets at once, counting every secret not yet revealed. Expired secrets count until they are removed on the next request. When it is full, creating a new link fails until space frees up. While more than 80 % of that is in use (16,000 on this site), new links can last at most 1 day.

Does the site use cookies or analytics?

The site where secrets are created and opened (onetimepass.pages.dev) loads nothing from other sites and has no analytics or cookies on any page. This information site (how it works and privacy) uses Google Analytics to count visits only if you accept. Each site remembers your theme choice, and this site your cookie choice, only in your own browser’s storage.

Share a secret