Quoted-Printable Encoder Decoder

Encode text to Quoted-Printable (QP) format or decode QP back to text. Supports RFC 2045 encoding rules.

  1. Home
  2. > Encoder & Decoder >
  3. Quoted-Printable Encoder Decoder

Encode to QP

Decode from QP

What is Quoted-Printable Encoding?

Quoted-Printable (QP) is a Content-Transfer-Encoding scheme defined in RFC 2045 (part of the MIME specification). It encodes binary data into ASCII text using =XX notation, where XX is the hexadecimal value of the encoded byte.

QP is designed for text content that is mostly ASCII but contains occasional non-ASCII characters. Unlike Base64, QP preserves readable ASCII text, making it ideal for email messages with special characters like accents or symbols.

QP Encoding Rules

  • ASCII printable characters (33-126 except =) are sent as-is
  • The = character is encoded as =3D
  • Non-printable characters (0-31, 127+) are encoded as =XX
  • Tab (09) and space (32) are allowed as-is, except at line end
  • Lines are limited to 76 characters (soft breaks use = at line end)
  • In header mode (RFC 2047), spaces become underscores (_)

How to Use This QP Encoder/Decoder

  1. Encode to QP — Type or paste text into the left panel, then click Encode to convert it to Quoted-Printable format.
  2. Decode from QP — Type or paste QP-encoded text into the right panel, then click Decode to convert it back to readable text.
  3. Header mode — Enable Header mode for RFC 2047 compliance (spaces become underscores, stricter encoding).
  4. Swap & Clear — Click Swap to exchange encode/decode values, Clear All to reset everything.

Common Use Cases

  • Email development — Encode email content with international characters for proper MIME transmission.
  • Email header encoding — Encode non-ASCII characters in Subject, From, and To headers using RFC 2047 Q-encoding.
  • Debugging email issues — Decode raw email source to inspect and troubleshoot QP-encoded content.
  • Data migration — Convert legacy text data that may contain QP-encoded content to plain text.
  • API development — Handle QP-encoded text in webhook payloads or email processing pipelines.

Frequently Asked Questions

What is the difference between Quoted-Printable and Base64?

Quoted-Printable is best for text that is mostly ASCII with a few special characters — it keeps the readable text visible. Base64 is more efficient for binary data but produces entirely encoded output that is not human-readable. QP typically results in larger output for binary data, while Base64 adds ~33% overhead regardless of content.

What does the =XX notation mean?

Each =XX sequence represents a single byte where XX is the hexadecimal value. For example, =C3=A9 decodes to the UTF-8 bytes for the character é (U+00E9). The = prefix tells the decoder that the following two hex digits represent an encoded byte.

What are soft line breaks?

QP limits lines to 76 characters. When a line would exceed this limit, a = is added at the break point followed by a line break (CRLF). The decoder ignores these soft breaks and continues decoding the next line. This tool automatically handles soft line breaks during decoding.

What is Header mode (RFC 2047)?

Header mode applies stricter QP encoding rules for email headers. In this mode, spaces are encoded as underscores (_) instead of =20, and certain characters that are normally allowed in body text are also encoded to ensure safe transmission in header fields.

Is this tool safe for sensitive data?

Yes. All encoding and decoding happens entirely in your browser using JavaScript. No data is sent to any server. Your content never leaves your device.

Help2Code Logo
Menu