Skip to main content

Password protect a PDF

Encrypt a PDF with AES-256 and an open password: without it, the document can no longer be opened. Encryption runs locally in your browser, with no upload.

  • Export
Automate

Embed this widget

Customize the result, check the live preview, then copy the code.

Preview

Embed code type

Code to copy

Responsive and automatically resized by Bethemesh.

Your files are processed locally in your browser and are never sent to our servers.

Drop your file here

Recommended size: up to 100 MB

The password will be required to open the PDF.

Was this tool useful?

How does this tool work?

Password-protecting a PDF encrypts the document: without the password, it can no longer be opened or read. It is the precaution to take before emailing a payslip, a medical file, a contract or a statement, especially if the message may be forwarded or the attachment intercepted. Encryption is applied in your browser; neither the document nor the password is transmitted.

The tool relies on qpdf, a reference library for handling PDFs, compiled to WebAssembly so it runs in the page. The document is encrypted with the AES algorithm and a 256-bit key, the strongest method defined by the PDF 2.0 standard (ISO 32000-2).

The password you enter becomes both the open password and the owner password. It is asked for twice to avoid a typo that would lock you out of the file. The resulting PDF opens normally in all recent readers (Acrobat, browsers, built-in system viewers), which then ask for the password.

The strength of the protection depends mostly on the password: AES-256 makes direct attacks on the encryption unrealistic, but a short or common password can be guessed by trial and error. Send it through a different channel from the document, for example by text message if the PDF goes by email.

How to use this tool

  1. Import the PDF

    Choose the document to protect; it stays on your device.

  2. Enter the password twice

    Both entries must match; a message warns you otherwise.

  3. Download the encrypted version

    The protected file will ask for this password every time it is opened. Test it before sending.

Use cases

Send personal documents

Protect payslips, tax notices or ID documents before emailing them.

Share a sensitive business document

Encrypt a quote, a contract or a confidential report intended for a client.

Store files on shared media

Keep private documents on a USB stick or shared cloud without leaving them readable by everyone.

Examples

A payslip to send

A passphrase of several words with digits and a symbol holds up far better than a 6-letter word. The password is then given to the recipient by phone, never in the same email as the file.

Input

payslip-march.pdf, password “Moon-Orchard-73!” entered twice

Result

PDF encrypted with AES-256 that asks for the password when opened

Tips and best practices

  • Use at least 12 characters, ideally a passphrase; Bethemesh offers a password generator in the Security category.
  • Keep the password in a password manager: there is no way to recover an encrypted PDF whose password is forgotten.
  • To only block printing or copying without preventing opening, use Change PDF permissions instead.
  • Do other transformations (merging, compressing, watermarking) before protecting: an encrypted PDF must be unlocked to be edited again.

Sources and references

Frequently asked questions

Which encryption is used?

AES with a 256-bit key, applied by qpdf. It is the highest level defined by the PDF standard and is supported by current readers.

What happens if I forget the password?

The document can no longer be opened. Bethemesh keeps neither the file nor the password and therefore cannot recover it.

Does the recipient need special software?

No. Common PDF readers, including those built into browsers, can open an AES-256 encrypted PDF once the password is entered.

Is the password sent to Bethemesh?

No. It is only used for the encryption performed in your browser and is neither stored nor transmitted.

Can I remove the protection later?

Yes, with Unlock a PDF and the password you chose.

Does the protection also prevent printing?

No. Once the document is opened with the password, every action is allowed. To restrict printing or copying, use Change PDF permissions.

Related tools

Tools similar or complementary to this one.

Works well with

Remove PDF password protection locally when you know the current password.

PDF & documentsUse this tool

Control printing, modifications and content extraction with an AES-256 owner password.

PDF & documentsUse this tool

Clean a PDF locally by removing metadata, JavaScript, automatic actions and embedded attachments.

PDF & documentsUse this tool
TutorialBest practicesBeginner

How to securely redact a PDF before sharing it

Learn why covering text is not enough, how secure PDF redaction removes sensitive information and why sanitization matters before sharing.

10 September 20262 min
GuideBest practicesBeginner

PDF: understand the format and manage documents properly

Understand how PDF files are structured, the difference between native and scanned PDFs, and the right operations for merging, reorganizing, converting or completing documents.

29 August 20263 min