How to convert TIFF to Base64
- Drop a
.tifor.tifffile on the box or pick it with the file picker. - Output as starts on Plain Base64, which is what most APIs expect. JSON adds the name, MIME type and size.
- Press Copy output. For large scans use Save as .txt and attach or upload the text file.
There is no resize or convert step on this page. Those options need the browser to decode the image, and only Safari can decode TIFF. The file is encoded byte for byte, so multi-page documents, compression and tags stay intact.
Where Base64 TIFF is used
TIFF is still the default output of many document scanners and fax systems, and it is common in archives, print workflows and geospatial data (GeoTIFF). When those files have to go into a JSON request, Base64 is the usual carrier:
- OCR and document-processing APIs that accept scanned pages as Base64 alongside PDFs and JPEGs.
- Fax and e-filing services that take multi-page TIFF documents.
- Records systems that store scans in a database text column or a JSON export.
Check that the receiver supports the compression your scanner used. Older systems may read uncompressed or LZW TIFF but not JPEG-compressed TIFF, and fax services often expect CCITT Group 3 or Group 4.
TIFF compression and Base64 size
TIFF can store pixels uncompressed or with several compression schemes. The choice changes the Base64 length enormously. A test with a generated text-only A4 page at 300 dpi (2480×3508 pixels), saved three ways:
| Stored as | TIFF file | Base64 length |
|---|---|---|
| 8-bit grayscale, uncompressed | 8,699,962 bytes | 11,599,952 chars |
| 1-bit black and white, uncompressed | 1,087,590 bytes | 1,450,120 chars |
| 1-bit, CCITT Group 4 | 15,270 bytes | 20,360 chars |
For a page of text, black and white with Group 4 compression is hundreds of times smaller than grayscale. Before you send scans through an API with a size limit, rescan or convert them in the scanner software instead of fighting the Base64.
TIFF in Base64
| Header bytes | Base64 | Byte order |
|---|---|---|
49 49 2A 00 (II*) | SUkqAA | little-endian, the more common order |
4D 4D 00 2A (MM*) | TU0AKg | big-endian |
49 49 2B 00 (II+) | SUkrAA | BigTIFF, for files over 4 GB |
A little-endian TIFF with its first directory at offset 8 starts SUkqAAgAAAA. To turn Base64 back into a file, use Base64 to File, which recognizes standard TIFF headers. For other image formats that browsers can display, see Image to Base64.
FAQ
Can I show a Base64 TIFF in a web page?
Only in Safari. Chrome, Edge and Firefox have no TIFF decoder, so a data:image/tiff URI in <img> or CSS renders as a broken image there. For web display, convert the scan to PNG, JPEG or PDF.
Does Base64 keep all pages of a multi-page TIFF?
Yes. Base64 encodes the whole file, so every page, the compression and the metadata are preserved. The receiver gets exactly the file you dropped.
What do SUkqAA and TU0AKg mean?
They are the two possible TIFF headers. SUkqAA is II*\0, a little-endian TIFF (the common case); TU0AKg is MM\0*, big-endian. BigTIFF files start with SUkrAA instead.