Skip to content
Marvin's Toolbox.

Search tools

Type to filter all tools

Color Palette Extractor

Pull the dominant colors out of any image as a ready-to-copy palette. Choose how many colors you want, copy each one as HEX, RGB or HSL, and export the whole palette at once.

Everything runs locally in your browser. Your data never leaves your device.

Drop an image here

or click to browse (PNG, JPEG, WebP, GIF, AVIF and more)

Everything stays in your browser. Images are never uploaded.

Next steps

Send this tool's output straight into another tool.

Convert a color between HEX, RGB, HSL, HSV, HWB, CMYK, OKLCH and OKLAB. Type into any field and the others update as you go, or pick the color visually. Reads CSS color syntax and keeps alpha where the format supports it.

Convert text into every case at once: title case in the APA, AP, Chicago, MLA, Bluebook, AMA and NYT styles, sentence case, upper, lower, camelCase, snake_case, kebab-case and more, each with its own copy button.

Count words, characters, sentences, paragraphs, lines and more as you type, with estimated reading and speaking time.

Remove duplicate lines from a list or text, keeping the first occurrence. Optionally ignore case and whitespace, or drop blank lines too.

Replace text in two modes: plain find and replace all, or regular expressions with flag controls and capture group references like $1.

Compare two texts and see every added, removed and changed line highlighted, side by side or inline, with the changed words marked within each line. Ignore case, whitespace or blank lines, read a summary of how much changed, and export the result as a unified diff.

Paste a UUID to see what it carries: version, variant, and for time-based versions the exact timestamp, clock sequence and node. Also shows the raw bytes, the 128-bit integer and the URN form.

Decode Base64 to text or encode text to Base64. Paste into the top box, read the result below, and flip the direction with one click. Handles Unicode correctly, reads URL-safe Base64, and shows binary payloads as a hex dump you can download.

Convert between scientific notation and full numbers as you type. Reads 1.23e5, 1.23 × 10^5 and plain numbers, shows the value written out, in normalized scientific notation and in engineering notation, and can round to any number of significant digits.

Sort the lines of a text alphabetically, naturally, by length, by numeric value or shuffled. Reverse the order with a switch, and optionally trim lines, drop blank lines and remove duplicates in the same pass.

Check two colors against the WCAG contrast rules. Type or pick a text and a background color, read the contrast ratio, see which AA and AAA checks pass, preview real text at the sizes WCAG distinguishes, and get suggested fixes when a check fails.

Create a QR code for text, a link, an email, a phone number, an SMS, Wi-Fi access or a contact card. Set the error correction level, size, margin and colors, then download it as PNG or SVG or copy it straight to the clipboard.

Paste a cron expression and get a plain English explanation, a field by field breakdown and the next times it would run, in your local timezone or UTC. Reads five field crontab syntax, six fields with seconds, names like MON and macros like @daily.

Work out an IPv4 or IPv6 network from an address with a prefix or netmask: network and broadcast addresses, usable host range, subnet mask, wildcard mask and address type. Adjust the prefix with a slider, read the binary breakdown, and split the network into smaller subnets.

Hash text or a file with MD5, SHA-1, SHA-256, SHA-512, SHA-3, BLAKE2, BLAKE3, CRC32 and more, all computed live as you type. Compare against an expected checksum and copy any digest.

Verify a checksum online: drop a file, paste the expected checksum and see instantly whether they match. The hash type is detected from the checksum itself, covering MD5, SHA-1, SHA-256, SHA-512, BLAKE3, CRC-32 and more, and sha256sum lines or whole checksum files can be pasted as-is.

Encode text for use in URLs or decode percent-escaped strings back to readable text. Choose component, full-URL or form encoding, unwrap double-encoded strings, and break a URL into its parts with every query parameter decoded.

Convert Unix timestamps in seconds, milliseconds, microseconds or nanoseconds to readable dates in your local time, UTC or any timezone, and turn any date back into a timestamp. Shows the live current timestamp and relative time.

Escape text into HTML entities or decode entities back to plain text. Choose named or numeric entities, escape only the unsafe characters or everything outside ASCII, and read the result live.

Paste a JSON Web Token to see its header and payload as formatted JSON, with the token color coded so each part maps to its output. Explains the registered claims, shows expiry as readable dates, flags expired tokens and can verify the signature with a secret or public key.

Compress text or a file with gzip, deflate, brotli or Zstandard and see the size before and after, the compression ratio and how long it took. One click tries every method and recommends the smallest result.

Decompress gzip, deflate, brotli or Zstandard data from a file or pasted Base64 and read the result as text or download it. Detects the format from the magic bytes where possible, with a manual override.

Paste anything that looks encoded and this tool works out what was used and undoes it, layer by layer. The whole BaseXX family from Base16 to Base85, binary, URL escapes, HTML entities, ROT13 and gzip, Brotli or Zstandard compression are detected in any combination, and every step of the chain is reported.

Escape or unescape a string for JSON, JavaScript, regex, shell, SQL, CSV, XML and more. Paste text, pick the target format and copy the result, in either direction.

Paste a PEM certificate to see its subject, issuer, validity dates, subject alternative names, key details, fingerprints and extensions in plain view.

Paste a 2FA secret or an otpauth:// link and watch the one-time codes tick live, with a countdown to the next code. Supports the digit counts, periods and algorithms real authenticators use.

Format code in JavaScript, TypeScript, JSON, JSON5, HTML, Vue, CSS, SCSS, LESS, Markdown, YAML, GraphQL, XML and SQL. Pick tabs or spaces, set the indent width, and format the input in place with one click.

Reveal the characters you can't see in a text: zero-width spaces, non-breaking spaces, bidi marks, control characters and CRLF versus LF line endings. Inspect every occurrence and clean them out with a click.

Test a regular expression against your own text and see every match highlighted as you type, with capture groups color coded and broken down match by match. Toggle any JavaScript regex flag, read the exact error when a pattern is invalid, and copy all matches as a list.

About the Color Palette Extractor

This tool reads the dominant colors out of an image and turns them into a palette you can copy. Drop a photo, screenshot or logo, choose how many colors you want with the slider, and each swatch shows the color as HEX, RGB and HSL along with how much of the image it covers.

The whole palette exports in one go: copy it as a hex list or a CSS custom-property block, or download it as a text or JSON file. A toggle can skip near-white and near-black pixels, which helps when a large background would otherwise crowd out the subject's colors.

What you can do

  • Extract a color palette from a photo, screenshot or logo.
  • Get the dominant colors of an image as HEX, RGB or HSL values.
  • Choose between 2 and 16 colors and see how much of the image each covers.
  • Copy the palette as a hex list or a CSS custom-property block.
  • Download the palette as a text or JSON file.
  • Skip near-white and near-black pixels to focus on the subject's colors.

How to use the Color Palette Extractor

  1. 1Drop an image or click the upload area to pick one.
  2. 2Set the number of colors with the slider, and turn on the extremes filter if a plain background dominates the result.
  3. 3Copy single values from a swatch, or export the whole palette as text, JSON or CSS variables.

How the colors are picked

The tool samples the image down to at most 100,000 pixels and groups them with a median cut quantizer, the same idea GIF encoders use to reduce colors. It splits the image's colors into as many groups as you asked for, always cutting the widest-spread group, and averages each group into one swatch. Fully transparent pixels are ignored, so a logo on a transparent canvas only reports the logo's own colors.

The share next to each swatch tells you how much of the image that group covers, which separates a true background color from an accent. The extraction is deterministic, so the same image and settings always produce the same palette.

Using the palette

One click copies a swatch in the notation you need, ready to paste into CSS, a design tool or code. To translate a color into other notations like OKLCH or CMYK, send it to the Color Converter. The CSS export names the colors --palette-1 through --palette-n, ordered from most to least common.

See and edit the EXIF metadata inside a photo, then download it with your changes or save a copy with all metadata removed, GPS included. It reads JPEG, PNG, HEIC and more, and edits JPEG files.

Copy the EXIF metadata from one photo onto another without changing the destination's pixels. That covers camera model, lens, focal length, exposure, GPS and more. Choose to replace all metadata or only fill in what the source provides.

Draw arrows, boxes, text, highlights and numbered steps on a screenshot, blur or pixelate anything private, crop the result and add a watermark. Undo works as you expect, and the finished image downloads as PNG or JPG or goes straight to your clipboard.

Convert images between JPEG, PNG, WebP and AVIF. Drop in as many as you like, pick a format, and dial in the quality for the lossy ones. When you convert to JPEG, choose the colour that fills any transparency. Live previews, download one or all at once.

See the RGB and luminance histograms of any image, with per-channel toggles, a linear or logarithmic scale, and exposure stats such as clipped shadows and highlights.

Shrink any image with as little quality loss as possible. Pick a WhatsApp, Instagram or Discord preset, or switch to Custom to hit a hard file size or a fixed quality, downscale with aspect-locked resolution sliders, and keep or strip EXIF metadata. Live preview, multiple images at once.