Compressed GIMP XCF Image
image/x-compressed-xcf
Released 1995
· by The GIMP Team
The image/x-compressed-xcf MIME type represents a compressed version of the XCF (eXperimental Computing Facility) file format, which is the native working project format for GIMP (GNU Image Manipulation Program). Because standard XCF files store complex, multi-layered pixel data with only basic RLE (Run-Length Encoding) compression, they can become extremely large. To mitigate this, GIMP natively supports saving and opening these files wrapped in standard gzip (.xcf.gz) or bzip2 (.xcf.bz2) compression algorithms, significantly reducing file sizes while maintaining all editable layers, masks, paths, and channels.
Technical Specifications
.xcf.gz.xcf.bz2.xcfgz.xcfbz2
DeflateBWT (Burrows-Wheeler)
application/x-xcf-compressedimage/xcf
Magic Bytes & HTTP Headers
\x1F\x8B\x08 or BZh
Browser Support Matrix
| Browser | Status | Min Version |
|---|---|---|
|
|
Not Supported | — |
|
|
Not Supported | — |
|
|
Not Supported | — |
|
|
Not Supported | — |
|
|
Not Supported | Legacy |
Advantages & Limitations
- Drastically reduces the massive file sizes of standard XCF project files, saving significant disk space
- Preserves 100% of the non-destructive editing data (layers, masks, paths, guides) from the GIMP workspace
- Uses standard, universally supported compression algorithms (gzip/bzip2) meaning the archive can be rescued or extracted by standard OS tools if GIMP is unavailable
- Increases file load and save times due to the CPU overhead required to compress and decompress the massive pixel arrays
- Impossible for automated tools to parse metadata or dimensions without first unarchiving the payload into memory
- File extension combinations (.xcf.gz) can confuse basic MIME sniffers which stop reading at the .gz extension
Developer Code Snippets
File Detection Steps
How to programmatically detect a image/x-compressed-xcf
file by reading its raw bytes:
- 1 Because the file is compressed, it will NOT start with the standard 'gimp xcf' magic string.
- 2 It will start with standard archive headers: 1F 8B 08 for gzip, or 42 5A 68 for bzip2.
- 3 To verify it is actually a compressed XCF, you must decompress the stream in memory and check the first 9 bytes of the extracted payload for the ASCII string 'gimp xcf ' (Hex: 67 69 6D 70 20 78 63 66 20).
Software Support
ImageMagick
Conversion Tools
Share & Embed
[](https://freewebptojpg.com/mime/image/compressed-xcf)
<iframe src="https://freewebptojpg.com/mime/image/compressed-xcf/embed" width="100%" height="280" style="border:1px solid #cbd5e1;border-radius:8px;" title="Compressed-XCF Specs"></iframe>
JSON API
All data on this page is available as a free, open JSON API. Use it in your project, documentation, or tooling.
GET https://freewebptojpg.com/mime/image/compressed-xcf.json
Open JSON
Frequently Asked Questions
What is an .xcf.gz file?
An .xcf.gz file is a GIMP XCF project file that has been compressed using the gzip algorithm to save disk space. GIMP handles the compression and decompression automatically in the background when you save or open the file.
How do I extract or open an image/x-compressed-xcf file?
You can open it directly in GIMP, which natively understands the compression wrapper. Alternatively, because it is just a standard archive, you can use extraction tools like 7-Zip, WinRAR, or the Linux 'gunzip' command to extract the raw, uncompressed .xcf file.
Can I view an .xcf.bz2 file in a web browser?
No. Web browsers do not support the GIMP XCF format, nor do they natively decompress arbitrary bzip2 image archives. You must export the image to a web-safe format like WebP, PNG, or JPEG from within GIMP.