cd /news/artificial-intelligence/remove-ai-watermarks Β· home β€Ί topics β€Ί artificial-intelligence β€Ί article
[ARTICLE Β· art-1535] src=github.com β†— pub= topic=artificial-intelligence verified=true sentiment=Β· neutral

Remove AI Watermarks

Tool that removes both visible and invisible AI watermarks from images generated by models like Google Gemini, ChatGPT, and Midjourney. It strips metadata such as SynthID, C2PA credentials, and EXIF labels, and offers features like batch processing and an "Analog Humanizer" to bypass AI image classifiers. The tool is available as a command-line interface or through a free web service at raiw.cc.

read9 min views22 publishedMay 19, 2026

Remove visible and invisible AI watermarks from images generated by Google Gemini (Nano Banana), ChatGPT / DALL-E, Stable Diffusion, Adobe Firefly, Midjourney, and other AI models.

Strips SynthID, C2PA Content Credentials, EXIF/XMP "Made with AI" labels, and visible sparkle overlays β€” all in one command.

Visible watermark removalβ€” Gemini / Nano Banana sparkle logo via reverse alpha blending (fast, offline, deterministic)** Invisible watermark removal**β€” SynthID, StableSignature, TreeRing via diffusion-based regeneration** AI metadata stripping**β€” EXIF, PNG text chunks, C2PA provenance manifests (PNG / JPEG / AVIF / HEIF / JPEG-XL), XMP DigitalSourceType**"Made with AI" label removal**β€” removes the metadata that triggers AI labels on Instagram, Facebook, X (Twitter)** Analog Humanizer**β€” film grain and chromatic aberration to bypass AI image classifiers** Smart Face Protection**β€” automatic extraction and blending of human faces to prevent AI distortion** Batch processing**β€” process entire directories** Detection**β€” three-stage NCC watermark detection with confidence scoring

Try it onlineβ€” don't want to install anything? Use[raiw.cc], a free web service powered by this library.

Before (Watermarked) After (Cleaned)
AI model Visible watermark Invisible watermark Metadata Our approach
Google Gemini / Nano Banana / Gemini 3 Pro
βœ… Sparkle logo βœ… SynthID v1 + v2 (default SDXL pipeline at native ~1024 px) βœ… C2PA + EXIF Alpha reversal + diffusion + metadata strip
OpenAI DALL-E 3 / ChatGPT
β€” β€” βœ… C2PA manifest Metadata strip
OpenAI ChatGPT Images 2.0 (gpt-image-2)
β€” βœ… C2PA manifest (verified) Diffusion regeneration + metadata strip
Stable Diffusion (AUTOMATIC1111, ComfyUI)
β€” βœ… DWT / steganographic βœ… PNG text chunks Diffusion regeneration + metadata strip
Adobe Firefly
β€” β€” βœ… Content Credentials (C2PA) Metadata strip
Midjourney
β€” β€” βœ… EXIF + XMP (prompt, model, seed) Metadata strip
StableSignature (Meta)
β€” βœ… In-model watermark β€” Diffusion regeneration
TreeRing
β€” βœ… Latent space watermark β€” Diffusion regeneration

Visible watermarks (logo overlays) are currently used only by Google Gemini / Nano Banana. Other services rely on invisible watermarks and/or metadata. Our diffusion-based regeneration works against any invisible watermark in pixel or frequency domain.

Google Gemini (internally codenamed Nano Banana) adds a visible sparkle logo to generated images using alpha blending:

watermarked = Ξ± Γ— logo + (1 βˆ’ Ξ±) Γ— original

We reverse this with a known alpha map (extracted from Gemini / Nano Banana output on a pure-black background):

original = (watermarked βˆ’ Ξ± Γ— logo) / (1 βˆ’ Ξ±)

A three-stage NCC (Normalized Cross-Correlation) detector finds the watermark position and scale dynamically, so it works even if the image was resized or cropped. After removal, residual sparkle-edge artifacts are cleaned via gradient-masked inpainting.

Speed: ~0.05s per image. No GPU needed.

Google embeds SynthID into every image generated by Gemini / Nano Banana. Other AI services use StableSignature, TreeRing, and similar schemes. These imperceptible frequency-domain patterns survive cropping, resizing, and JPEG compression.

The removal pipeline (default profile, SDXL):

image β†’ resize to ~1024px (SDXL native) β†’ encode to latent space (VAE)
      β†’ add controlled noise (forward diffusion)
      β†’ denoise (reverse diffusion, ~50 steps at strength 0.05)
      β†’ decode back to pixels (VAE) β†’ upscale to original resolution

SDXL is the default since May 2026: empirically defeats SynthID v2 on Gemini 3 Pro outputs, where the older SD-1.5 pipeline at 768 px did not. The SD-1.5 path was removed once it was verified not to handle v2.

Face Protection: before diffusion, YOLO detects people in the image and extracts them. After diffusion, the original faces are blended back with a soft elliptical mask to prevent AI distortion of facial features.

Analog Humanizer: optional film grain and chromatic aberration injection that makes the output indistinguishable from a photo of a screen, defeating AI-generated image classifiers.

AI tools embed generation metadata that social platforms use to show "Made with AI" labels:

EXIF tagsβ€” prompt, seed, model hash, sampler settings (Stable Diffusion, Midjourney)** XMP DigitalSourceType**β€”trainedAlgorithmicMedia

tag used by Instagram, Facebook, and X (Twitter) to show "Made with AI"PNG text chunksβ€” ComfyUI workflows, AUTOMATIC1111 parameters** C2PA Content Credentials**β€” cryptographic provenance manifests from Google Imagen, OpenAI DALL-E, Adobe Firefly

The cleaner parses each layer, removes AI-related fields, and preserves standard metadata (Author, Copyright, Title).

Install as an isolated CLI tool β€” no need to manage virtual environments:

pipx install git+https://github.com/wiltodelta/remove-ai-watermarks.git

uv tool install git+https://github.com/wiltodelta/remove-ai-watermarks.git

To update to the latest version:

pipx upgrade remove-ai-watermarks

uv tool upgrade remove-ai-watermarks

Prerequisites: Python 3.10+ and pip

(or uv).

git clone https://github.com/wiltodelta/remove-ai-watermarks.git
cd remove-ai-watermarks

pip install -e .

uv pip install -e .

After installation the remove-ai-watermarks

command is available system-wide.

Note: The base install covers visible watermark removal and metadata stripping. For invisible watermark removal (SynthID etc.), install GPU dependencies:

pip install -e ".[gpu]"   # or: uv pip install -e ".[gpu]"

Invisible removal uses diffusion models and a GPU for reasonable speed.


cp .env.example .env
pip install -e ".[dev]"
uv pip install -e ".[dev]"

pytest

./maintain.sh
remove-ai-watermarks all image.png -o clean.png

remove-ai-watermarks batch ./images/ --mode all
remove-ai-watermarks visible image.png -o clean.png

remove-ai-watermarks invisible image.png -o clean.png --humanize 4.0

remove-ai-watermarks metadata image.png --check
remove-ai-watermarks metadata image.png --remove

remove-ai-watermarks batch ./images/ --mode visible
python
from remove_ai_watermarks.gemini_engine import GeminiEngine
import cv2

engine = GeminiEngine()
image = cv2.imread("watermarked.png")

result = engine.detect_watermark(image)
print(f"Detected: {result.detected} (confidence: {result.confidence:.1%})")

clean = engine.remove_watermark(image)
cv2.imwrite("clean.png", clean)
python
from remove_ai_watermarks.metadata import has_ai_metadata, remove_ai_metadata
from pathlib import Path

if has_ai_metadata(Path("image.png")):
    remove_ai_metadata(Path("image.png"), Path("clean.png"))
  • Python β‰₯ 3.10 Visible removal / metadata: CPU only, no GPU required** Invisible removal**: GPU recommended (CUDA or MPS), works on CPU (slow)

SSL certificate error (CERTIFICATE_VERIFY_FAILED

):

pip install certifi

/Applications/Python\ 3.*/Install\ Certificates.command

First run is slow β€” this is expected. The tool downloads model weights (~2 GB) on first launch. Subsequent runs use cached models.

noai-watermarkby mertizci β€” invisible watermark removal engineGeminiWatermarkToolby Allen Kuo (MIT) β€” visible watermark removal algorithmCtrlRegenby Liu et al. (ICLR 2025) β€” controllable regeneration pipeline- NeuralBleach (MIT) β€” analog humanizer technique

Tracked but not yet implemented:

SynthID-Image v2 automated regression test. The default SDXL profile defeats v2 per manual checks against theGemini app's "Verify with SynthID" feature on a Gemini 3 Pro output (May 2026). An automated end-to-end test would need either programmatic access to theSynthID Detector portal(waitlist for media professionals and researchers) or an offline surrogate detector. Open.AVIF / HEIF / JPEG-XL detection limits. Removal strips top-level C2PAuuid

and JUMBFjumb

boxes. EXIF/XMP boxes inside these containers are not yet scrubbed (PNG and JPEG are fully covered).Video pipeline (: per-frame inpainting and tracking for Sora 2 dynamic logo, Veo 3.1 badge, Kling, Runway. Separate package, not folded into this repo.noai-video

)

Won't fix:

Nightshade / Glaze / PhotoGuard removal. These are defensive perturbations used by artists to protect their work from being scraped into AI training sets. Removing them attacks artists, not AI provenance. Out of scope.

Watermarking and provenance for AI-generated content is now regulated in several jurisdictions. The table below summarises the May 2026 status. None of this is legal advice.

Jurisdiction Instrument Status (May 2026) Relevance
EU AI Act, Article 50(2) Marking obligations postponed to 2 December 2026 under the December 2025 omnibus agreement. Code of Practice finalising May/June 2026.
Removing mandated provenance markers with intent to deceive may be sanctioned under national implementations.
US (federal) COPIED Act Enacted 2025. Criminalises removal of provenance information with intent to deceive about content origin. The tool itself is lawful; usage may not be.
US (state) CA AB 2655, TX SB 751, similar In force. Content-specific (election deepfakes, sexual deepfakes). Not tool-specific.
China Deep Synthesis Regulation, 2025 updates In force. Mandatory visible label for AI content. Removal is an administrative offence.
UK Online Safety Act, 2025 transparency extension In force. Platform obligations, not user obligations.

This tool defends already-distributed AI imagery against automatic detection systems (social-platform "Made with AI" labels, third-party classifiers, content-policy filters). It does not retroactively anonymise generation.

In particular, SynthID-Image v2 (Google, deployed October 2025 with Gemini 3 Pro / Nano Banana Pro / Imagen 4 / Veo) embeds a 136-bit payload (arxiv 2510.09263). The payload is believed to encode a user / session identifier. If the original watermarked file ever passed through a system controlled by the prompt originator (a saved Gemini account history, a screenshot uploaded to a Google product, a backup), Google retains the ability to link that original to the generating account. Stripping the watermark from a copy you possess does not erase Google's server-side record.

Use cases where the threat model fits:

  • You generated the image yourself, want to publish it as your own work, and accept the consequences if Google ever publishes their detector logs.
  • You are running a security / robustness evaluation.
  • You are preserving art or historical record against false-positive "AI-generated" labels.

Use cases where the threat model does not fit:

  • Generating an image, expecting that removing the watermark anonymises you to Google. It doesn't.
  • Distributing AI-generated content while claiming human authorship. The watermark is one of several traceability layers.

This tool is intended for legitimate purposes such as:

  • Privacy protection (removing metadata that leaks user account identifiers).
  • Art preservation and fair-use research.
  • Removing false-positive "Made with AI" labels from human-edited photographs.
  • Security research and watermark robustness study.

Removing AI provenance markers to misrepresent AI-generated content as human-created may violate the laws above, the DMCA, and platform terms of service. Users are solely responsible for ensuring their use complies with all applicable laws. The authors do not condone use of this tool for deception, fraud, or any activity that violates applicable laws or regulations.

MIT

── more in #artificial-intelligence 4 stories Β· sorted by recency
── more on @google gemini 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain β€” perfect for shipping the agent you just read about.

$git push zahid main
β†’ Live at https://your-agent.zahid.host βœ“
Get free account β†’ Pricing
from €0/mo Β· no card required
LIVE [news/remove-ai-watermarks] indexed:0 read:9min 2026-05-19 Β· β€”