Compressed PNG Metadata: What Text Scans Can Miss
Understand PNG tEXt, zTXt and iTXt metadata, why compressed text can evade keyword scans, and how to verify the cleaning scope used on a shared copy.

A PNG can contain text that you cannot find by searching its raw bytes for a recognizable word. Some text chunks compress their content. The text still exists, but a plain string search sees the compressed representation rather than the original sentence.
That distinction matters when checking prompts, comments or private workflow details. A missing keyword is not proof that a PNG has no text metadata. Inspect the chunk types and use a reader that understands the relevant encoding before deciding what remains in the file.
Three text containers, different inspection needs
PNG defines tEXt, zTXt and iTXt chunks. A tEXt chunk holds text without compression. zTXt uses compressed text. iTXt supports international text and can also use compression. These structures are separate from the IDAT chunks that carry the main compressed image data.
A keyword identifies the purpose of a text chunk. For example, a keyword might say Comment or Copyright. That identifier and the actual text are not the same thing. A visible keyword can tell a scanner that a text chunk exists even when the useful content requires decompression.
The W3C specification defines the formats; it does not imply that every metadata checker fully implements them. A tool may list a zTXt chunk while never displaying its decoded contents. Treat a container finding and a complete content inspection as different levels of evidence.
A reproducible example with an ordinary comment
Use a disposable PNG and a tool or script that can create a valid zTXt chunk with a correct length and CRC. Set its keyword to Comment and compress a harmless sentence containing the word workflow. Keep the original PNG so that you can compare the image-data chunks later.
Now compare three observations: whether the file contains a zTXt chunk, whether a raw byte search finds workflow, and whether a decompression-aware reader displays the sentence. The intended lesson is the difference between stored bytes and decoded text. The exact compressed byte sequence depends on the input and compressor.
For this article's repository check, a synthetic Comment zTXt chunk containing a compressed workflow sentence was inserted into the existing PNG fixture. The current AI-only cleaner retained that chunk, while the full-cleaning scope removed it. Both outputs retained the fixture's IDAT bytes. This is a narrow synthetic test, not a benchmark across PNG applications or a test of AI detection.
Why AI-only and full cleaning can disagree
The current PNG cleaner recognizes certain AI-related patterns by inspecting a bounded raw sample of a text chunk. It does not decompress zTXt content before applying those pattern checks. A keyword such as workflow can be caught directly, while an ordinary keyword with relevant text only inside the compressed payload can be missed.
This explains why two PNGs containing similar human-readable information can receive different treatment. Their keywords, encoding and packet layout may differ. It does not mean the compressed version is encrypted or permanently hidden; a suitable reader can decompress it.
The full-cleaning path removes supported PNG text chunk types regardless of whether a known AI word appears. That broader scope can remove the compressed comment, but also removes useful captions or copyright text stored in those chunks. It is a scope choice with a preservation tradeoff, not a more accurate judgment about whether an image is AI-generated.
Choose according to what must not be shared
If your requirement is to remove a particular private prompt or comment, first establish where it is stored. Use a detailed reader to identify the keyword and decoded value. A generic clean result from a limited scanner cannot substitute for inspecting the target field.
If no text metadata is needed in the public copy, broader cleaning can be easier to verify than a pattern-based selection. Preserve the original privately so that useful credits, settings or reproducibility information are not lost from your archive. If some text must stay, use a field-aware editor and review the result.
The current website does not offer a per-chunk editing interface where you can choose arbitrary PNG text entries individually. Its available scopes operate according to predefined rules. Do not infer a capability to preserve one property inside a removed packet unless a tool actually supports that operation.
Check image data separately from metadata
After cleaning, verify that the output opens and has the expected dimensions and transparency. A chunk-level comparison can establish whether IDAT data was preserved in a controlled example. That is more specific than comparing whole-file sizes, which change when metadata is removed.
Do not use an unchanged image appearance as evidence that the comment disappeared. Metadata can remain while the pixels look identical. Equally, a smaller file does not establish that every private field was removed. You need both the content check and the image-integrity check.
The site's PNG path copies retained chunks instead of repainting the image to a canvas. That supports metadata-only operations for the structures it handles. It does not guarantee that arbitrary private chunks or unusual extensions are removed, and it does not erase a visible watermark in the image.
Troubleshoot a remaining text finding
If the checker still lists a text chunk after AI-only cleaning, inspect its actual contents before assuming failure. It may contain a benign copyright notice that the selected rules intentionally retained. If your goal was to remove all text, confirm that you chose the broader scope and checked the downloaded output.
If the target sentence remains after an editor save, trace that later export independently. The editor may have written a new text chunk. Check the final file after the last operation, not only the intermediate cleaned copy.
A responsible conclusion names the scope and the evidence: the supported text chunks were removed from the inspected PNG, or the selected field is absent in the detailed reader. Neither statement promises that a social platform will stop recognizing generated imagery. Compression, metadata and pixel-based classification are separate issues.
Frequently asked questions
Is compressed metadata encrypted?
No. Compression changes the representation to reduce size. A reader that implements the format can decompress it without a secret key.
Does deleting text chunks remove image transparency?
Transparency is not stored as a PNG text comment. The current cleaner copies image and transparency-related structures, but you should still open the output and verify the intended appearance.
Educational information only, not legal advice. Process only files you own or are authorized to use, and follow applicable disclosure requirements.