Image color changer:
replace one color with another

Change the color of an image by picking the color to replace, choosing its new color and setting how close a pixel must be to count as a match. Matching pixels receive the target color or shading shift. The tool runs in your browser, shows the original and the result, and saves a PNG.

Choose an image

Choose or drop one image. JPEG, PNG, WebP, SVG, TIFF and other decodable images. Nothing is uploaded.

No image selected.

Replacement settings

Use a six-digit hex color, such as #FFFFFF.

Use a six-digit hex color, such as #FFFFFF.

Or sample a pixel from the original image.

0% matches exactly. 100% matches every visible pixel.

Shading keeps each channel’s offset from the source color. Values outside 0–255 are clipped.

Choose an image to begin.

Original

Choose an image to begin.

Click or tap to sample. Focus the image and use arrow keys for individual pixels; Enter samples the current X and Y. Coordinates start at 0 in the top-left. Checkerboard is display only. At 100% or 200%, scroll inside the preview to reach other pixels.

Result

Your replaced colors will appear here.

How to change the color of an image

Select Choose image and pick a file from your device, or drop one image in the dashed area. The line under the button lists its name, pixel size and file size, and the Original preview appears. Type a six-digit hex value in Source color, or click or tap a spot on the Original preview to copy that pixel's color into it. Then set Target color, the color that matching pixels become.

Move the Tolerance (RGB distance) slider to set how wide the match is, and pick a Replacement mode. Select Replace color to preview the result, or select Download PNG to prepare and save it directly. The Result preview shows the changed and matched pixel counts.

Use Preview size above either image to fit it to the panel, or inspect it at 100% or 200%. Scroll inside an enlarged preview to see its edges. Preview size does not change the PNG's dimensions or colors.

  1. Select Choose image and pick an image, or drop one in the dashed area.
  2. Set Source color, or sample it from the Original preview.
  3. Set Target color, Tolerance and Replacement mode.
  4. Select Download PNG to save, or select Replace color to compare the previews first.

How tolerance decides which pixels match

Tolerance compares each visible pixel with the source color as a distance between their red, green and blue values. The largest possible distance, from black to white, is about 441.7, and the percentage is a share of it. At the default 10 percent, a pixel matches when its distance is 44.17 or less. At 0 percent only the exact source color matches, and at 100 percent every visible pixel does.

For example, an off-white #F0F0F0 sits 25.98 from pure white #FFFFFF, which is 5.88 percent. With #FFFFFF as the source, that pixel stays as it is at 5 percent and changes at 10 percent. Photos and scans hold many close shades, so raise the slider in small steps and run Replace color again until the Result preview covers the area you want. Alpha is not part of the distance.

Solid target color or Keep RGB shading

Solid target color sets every matching pixel to exactly the target color. That suits flat artwork such as logos, icons and charts, where one area has one color. Keep RGB shading instead adds the difference between the target and source colors to each matching pixel, so lighter and darker pixels keep their offset.

With source #3060C0, target #C03060 and a tolerance of 15 percent, the blues #3060C0, #2050B0 and #5080E0 become #C03060, #B02050 and #E05080 in shading mode. In solid mode all three become #C03060, and the shading between them is gone.

Each channel is clipped to the range 0 to 255, so a large shift can flatten detail or change the hue. Shading #E01010 from red #FF0000 to blue #0000FF gives #0010FF, which is no darker than the target. This is a plain arithmetic shift, not a photo-realistic recolor.

What the PNG contains

The download is a PNG named after the original with -replaced added, for example logo-replaced.png. It has the pixel size shown under the chooser, after the photo's orientation is applied. Alpha is never changed, so every pixel keeps its transparency. Canvas rounding can change the stored RGB of partly transparent pixels, including pixels outside the match. Fully transparent pixels can lose their stored RGB values.

Every Replace color run starts again from the original, so changes do not pile up while you try settings. The line under the Result preview lists changed pixels, matched pixels out of the total, and the PNG file size. The two counts differ when a matching pixel already has the target color.

The PNG is a new 8-bit sRGB file. Animation, extra pages, metadata such as EXIF, and HDR data are not kept. Browser color conversion can shift stored values slightly, and the file is encoded again even when no pixel changed.

Limits

The tool matches colors across the whole image. It does not detect objects, people, text or backgrounds, so a similar color elsewhere in the picture changes too. There is no AI, no perceptual color model and no soft edge: a pixel matches or it does not. A smoothed edge between red and white holds blends such as #FF8080, about 41 percent away from #FF0000, so a low tolerance leaves a thin rim of the old color.

You work on one image and one source color at a time. To change two colors, download the first result, choose that PNG as the new image and run again. Choosing a new file replaces the current one.

The chooser opens JPEG, PNG, WebP, SVG, TIFF, AVIF and other images your browser can decode. A multipage TIFF uses its first page, and an animated image gives one frame. An SVG is drawn without its external files. A very large image can exceed your browser's memory.

Questions

Can I change the color of a PNG image?

Yes. Choose the PNG, set the source and target colors and select Replace color. The result is also a PNG and the alpha channel is not changed, so transparent areas stay transparent. Fully transparent pixels are skipped by the match, and sampling one shows a message asking you to pick a visible pixel.

How do I change the color of a JPEG image?

Choose the JPEG like any other image, then sample or type the color to change. JPEG compression leaves small color variations, so an exact match at 0 percent can miss pixels that look the same. Raise the tolerance until the Result preview covers the area. The download is a PNG, not a JPEG.

Can I recolor the whole image at once?

Yes. Set Tolerance to 100 percent so every visible pixel matches. Keep RGB shading then shifts every pixel by the same difference between target and source, which tints the whole picture and keeps its light and dark areas within the 0 to 255 range. Solid target color at 100 percent fills every visible pixel.

Does this tool use AI to recolor images?

No. It compares red, green and blue values with a fixed distance formula and changes the pixels inside the tolerance. It does not recognize objects, skin, sky or backgrounds. To change only one object, that object needs a color that appears nowhere else in the picture, or a tolerance narrow enough to leave the rest alone.

How do I pick the exact color to replace?

Click or tap the spot on the Original preview. Its hex value goes into Source color, and the status line shows its X and Y position and alpha. You can also type Pixel X and Pixel Y and select Use pixel as source, or focus the preview and step one pixel at a time with the arrow keys.

Why does the result say no visible pixels changed?

No visible pixel is within the tolerance of the source color, or the matching pixels already have the target color. Sample a pixel from the area you want to change, raise the tolerance and select Replace color again. The PNG is still encoded again, so it can differ from your original file in size and metadata.

Does my image leave this device?

No. The image is opened, matched and encoded as a PNG in your browser on this device. The tool does not upload, log or store it. Cancel & clear, successfully opening another image and leaving the page each release the image and the result from the page.