Skip to content
ZeroServer.tools

PNG Metadata to JSON

Parse a PNG's binary chunk structure and extract embedded tEXt/iTXt/zTXt text metadata as JSON — nothing is uploaded.

Drop a PNG file or click to browseProcessed entirely in your browser — nothing is uploaded

How PNG metadata extraction works

A PNG file is a fixed 8-byte signature followed by a sequence of length-prefixed chunks ([4-byte length][4-byte type][data][4-byte CRC]). Alongside required chunks like IHDR (dimensions, bit depth, color type) and IDAT (pixel data), encoders and editors often embed free-text metadata in three optional chunk types: tEXt (plain Latin-1 key/value pairs, e.g. Author or Description), zTXt (the same, zlib-compressed), and iTXt (UTF-8 text that supports international keywords and can optionally be compressed too). This tool reads the raw bytes of your file with a DataView, walks the chunk list, and decodes any text chunks it finds — using the browser's native DecompressionStream("deflate") API to inflate the zlib-compressed chunks — then serializes everything to JSON. It uses the same low-level binary-parsing approach as the EXIF Viewer, just applied to PNG's chunk format instead of JPEG's marker segments. Common places to find embedded PNG text metadata include screenshots (software/OS info), AI-generated images (prompt/model parameters), and files exported from design tools (author, copyright, or software comments).

Built and maintained by Meet Shah · Last updated

What this tool is used for

  • Reading the text chunks a PNG carries, which most viewers never show.
  • Checking whether a generated image embedded prompt or tool metadata.
  • Inspecting a PNG's chunk structure to understand a file.
  • Confirming an export stripped metadata as intended.
  • Finding a colour profile or gamma chunk.

Frequently Asked Questions

What metadata does a PNG carry?
Text chunks — tEXt, zTXt and iTXt for compressed and international text — plus pHYs for physical dimensions, gAMA and iCCP for colour, and tIME for modification time. All of them are optional and most tools write only a few.
Where does AI image metadata live?
In a tEXt chunk, usually keyed parameters or prompt. Stable Diffusion and several other tools write the full generation parameters there, which is why an image can carry its own prompt, seed and model — and why sharing one discloses all of it.
How is PNG metadata different from EXIF?
PNG uses its own chunk structure rather than EXIF, though an eXIf chunk was added later to carry it. That is why a camera JPEG converted to PNG typically loses its EXIF entirely — the container changed and most converters do not migrate it.
Does a canvas round trip preserve metadata?
No, and this matters. Re-encoding through a canvas produces a fresh PNG with no text chunks at all, so any edit in a browser silently strips everything. That is a privacy improvement and a real loss if the metadata was the point.
How does chunk structure make this readable?
Every chunk carries a length, a four-character type, its data and a CRC — so a parser can walk the file and skip anything it does not understand. That design is why PNG has been extended repeatedly without breaking older readers.

Common errors and gotchas

  • Assuming a PNG carries EXIF the way a JPEG does, when its metadata lives in different chunks.
  • Publishing a PNG whose text chunks still hold prompts, paths or tool details.
  • Expecting a viewer to show these chunks, since most ignore them entirely.
  • Confusing tEXt, iTXt and zTXt, which differ in encoding and compression.
  • Treating an absence of text chunks as an absence of identifying information.

Related Developer Utilities tools

Private & free — this tool runs entirely in your browser.

IndieKit — Ship your Next.js startup in days.affiliate