Online Tool Store Online Tool Store

Color Replacer

Click a color in your image, pick a replacement, and swap it with a hard edge or a soft blend. Export as PNG or JPEG — all in your browser.

🔒 This tool runs entirely in your browser. Your files are never uploaded to a server.

Or drag and drop an image here.

Click the image below to pick the color you want to replace.

Download PNG

How it works

  1. Choose an image — click to browse, or drag and drop it onto the upload area — then click on it to pick the color you want to replace.
  2. Choose the replacement color and a tolerance. Turn on "Soften edges" for a gradual blend instead of a hard cutoff.
  3. Click "Replace color". Not quite right? Click "Reset to original" and try again — nothing is uploaded, so there's no cost to experimenting.
  4. Pick PNG (keeps transparency) or JPEG (smaller, no transparency) and download the result.

The method

Every pixel's color is compared to the target color using RGB distance; pixels within the chosen tolerance are recolored:

distance² = (r₁−r₂)² + (g₁−g₂)² + (b₁−b₂)²

With "Soften edges" on, that cutoff stops being a cliff: pixels in the outer 20% of the tolerance radius blend linearly toward the replacement color instead of switching all at once, so a gradient or an anti-aliased edge doesn't come out looking cut with scissors.

FAQ

What is a color replacement tool?

A tool that finds every pixel close to a color you pick and swaps it for a different color, in one pass across the whole image — rather than selecting or painting each area by hand.

What does tolerance control?

How close a pixel's color needs to be to the "replace this color" swatch to get swapped. Low tolerance only replaces near-exact matches; higher tolerance catches a wider range of similar shades.

Can I pick the source color directly from the image?

Yes — click anywhere on the image and that pixel's color fills the "replace this color" swatch.

What does "Soften edges" do?

Without it, a pixel is either fully replaced or left untouched, which can leave a hard, jagged line wherever the tolerance cutoff falls across a gradient or an anti-aliased edge. With it on, pixels near that cutoff blend gradually between the original and replacement color instead of switching all at once — useful on photos and soft-edged graphics, less necessary on flat, solid-color artwork.

Can I export as JPEG instead of PNG?

Yes. PNG is the default because it preserves transparency; switch to JPEG for a smaller file when you don't need transparency. JPEG has no transparency channel, so any transparent area is filled white before export rather than left to a browser's default (which is often an unwanted black fill).

Can I undo a replacement?

Yes — "Reset to original" restores the image you uploaded, so you can retry with different colors or tolerance without re-uploading. There's no multi-step undo history beyond that single reset.

Is my image uploaded anywhere?

No — replacement happens locally on a canvas in your browser.

How we compare

FeatureOnline Tool Storeimgonline.com.uaLunaPic
Live preview — no upload-and-wait
Hard swap or a soft blended edge, in one step Single intensity slider onlySeparate tool for a softer effect
Choose PNG or JPEG, with a quality slider for JPEG Not shown on this page
Your image never leaves your device Not confirmed
No account required

For a whole-image color swap, this covers it end to end without a round trip to a server. If the job is recoloring one region of a photo — a shirt, say — rather than every matching pixel across the whole image, a brush-based tool like Pixlr's Color Replace paints selectively instead of matching by color everywhere; that's a different job from a global swap, and a heavier one.

Explore related tools

Embed this tool

Paste this on your own site — it stays free, and every file still stays in your visitor's browser, not yours or ours.