PDF to Base64 Converter Online Free
Convert any PDF file to a Base64-encoded string. Copy the full string or preview it inline. Free, private, runs entirely in your browser.
Click to select a PDF file, or drag and drop
Your file never leaves your browserHow to Convert a PDF to Base64
- Upload the PDF file you want to encode.
- Click Convert to Base64 — the file is read and converted to a Base64 string entirely in your browser.
- Copy the full Base64 string using the copy button, or preview the first and last characters inline.
Example
A 50 KB PDF converts to roughly 67 KB of Base64 text (Base64 encodes every 3 bytes as 4 characters). The output string always starts with JVBERi0, which is the Base64 encoding of the PDF magic bytes %PDF-.
Common Use Cases
- Embedding a PDF directly into a JSON payload or API request body.
- Storing a PDF as a text column in a database that doesn't support binary blobs.
- Including a PDF as an inline data URI in an HTML document.
FAQ
- Why does the Base64 string look longer than the file? Base64 encoding expands data by roughly 33% — three binary bytes become four printable characters, so the output is always about a third larger than the original.
- Is my file uploaded anywhere? No — encoding happens entirely in your browser.
