Dokaz API › Docs › Image metadata remover

Remove EXIF and GPS metadata from photos API

A photo from a phone can carry where it was taken to within a few metres, the phone's serial number, the time, the editing app, and a thumbnail of the picture before it was cropped. Marketplaces, listing sites, support desks and anything that republishes user uploads should remove that before the image goes public.

This endpoint walks the file's own structure and keeps only what draws the image. The compressed image data is copied byte for byte, so the result decodes to exactly the same pixels - no quality loss, no size growth - and the colour profile and orientation are kept by default so the picture still looks right.

Request

curl -X POST https://api.dokaz.net/v1/image/strip \
  -H "content-type: image/jpeg" --data-binary @photo.jpg -o clean.jpg -D -

curl -X POST "https://api.dokaz.net/v1/image/strip?keep_icc=0&keep_orientation=0" \
  --data-binary @photo.jpg -o bare.jpg

The response is the image itself, in the same format. x-metadata-removed lists what was taken out (exif, xmp, iptc, comment, thumbnail, text, ...), x-bytes-removed how much. The live example sends a tiny PNG carrying a hidden text comment. Up to 10 MB per image.

Try it live — this runs against the free tier from your browser.

Pricing

100 calls a day are free with no key. Need more? Starter is $9/month for 10,000 calls across every product, key issued instantly.

Questions

Does it recompress the image?

No. It never decodes the image: it copies the compressed data as is and drops the metadata around it, so the pixels are identical to the original's - checked by decoding both with Pillow and OpenCV and comparing every pixel.

Why is my photo still the right way up?

Orientation is the one EXIF field that changes how the image looks, so it is kept as a tiny EXIF block holding nothing else. Pass keep_orientation=0 to remove it too.

Which formats?

JPEG (baseline and progressive) and PNG, detected from the bytes. Anything else, or a truncated or corrupt file, is refused with a 400 rather than passed through half-cleaned.

Related