Colors Le logo

Colors Le

Extracts color values, source positions, and notation from code, stylesheets, markup, and design-token files.

Install Colors Le

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "colors-le": {
      "command": "npx",
      "args": [
        "-y",
        "colors-le-mcp"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

We couldn’t confirm it starts correctly

The install command started, but didn't respond the way we expected when we tried to talk to it.

npx -y colors-le-mcp

initialize succeeded but no response to tools/list.

This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked Today.

Overview

The colors-le MCP server extracts colors from supplied source content and reports each value with its notation and 1-based line and column. Its single `extract_colors` tool accepts content plus optional format, filename, deduplication, and result-limit parameters over MCP stdio. It recognizes CSS-family syntax, HTML, JavaScript, TypeScript, SVG, JSON, YAML, TOML, Markdown, and plain text. Reach for it when an agent needs to audit palettes or locate color literals without giving the server filesystem or network access.

Use cases

  • Audit colors across stylesheet and source files
  • Locate color literals by line and column
  • Review design-token files for repeated colors
  • Check whether a large extraction was truncated
  • Provide palette data to an MCP-compatible coding agent

Key features

  • Extracts colors from code, stylesheets, markup, and token files
  • Reports original notation and 1-based source positions
  • Supports CSS Color 4 syntax and named colors
  • Offers deduplication and result limits
  • Runs over MCP stdio without API keys or file access

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 1d ago

Recent health check succeeded.

8/8 checks healthy over the last 47d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 2d ago via OSV.dev · colors-le-mcp (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars1Stargazers on the source repository.
npm downloads1.4kPackage downloads in the last 30 days.
Last commit2d agoMost recent push to the default branch.
Install checkInconclusiveStarted but did not complete the MCP handshake in our test.

How Colors Le works

What the colors-le MCP server does

The colors-le MCP server exposes color extraction to MCP-compatible agents through the extract_colors tool. It accepts document content directly rather than opening files, then identifies color literals and returns their normalized color, original notation, and 1-based line and column position. Results can be deduplicated and limited; the default cap is 500 entries, with meta.truncated indicating that more matches were available.

Supported inputs include CSS, SCSS, LESS, Stylus, HTML, JavaScript, TypeScript, SVG/XML, JSON, JSONC, YAML, TOML, Markdown, and plain text. Files in other language modes are treated as raw text and identified as unknown in the metadata. The parser ignores colors in comments and supports hexadecimal forms, functional RGB and HSL syntax, CSS Color 4 functions, named colors, and several SVG or markup attributes.

How it works

Send source text to extract_colors with optional format and filename values. The format helps select language-aware parsing rules, while the filename can provide context in the response. Optional dedupe behavior reduces repeated values, and maxResults controls the returned result count.

The server performs content-in, data-out processing. It does not read files and does not make network requests. This makes it suitable for agents that already have file contents from an editor, repository tool, or another workflow.

Setup and configuration

Run the colors-le MCP server with Node and npx:

config.json
{
  "mcpServers": {
    "colors-le": {
      "command": "npx",
      "args": ["-y", "colors-le-mcp"]
    }
  }
}

The package is published as colors-le-mcp. Hosts that support MCP over stdio can launch it with npx -y colors-le-mcp; alternatively, install it globally with npm install -g colors-le-mcp and use the colors-le-mcp executable. Pin a package version when a fixed release is preferred. No environment variables, API key, or server-specific configuration are required.

Claude Code can register it with claude mcp add colors-le -- npx -y colors-le-mcp. VS Code 1.101 and later can obtain the tool through the Colors-LE extension's agent mode, while Cursor and Windsurf can be pointed at the stdio command.

Tools and capabilities

The colors-le MCP server provides one documented tool:

  • extract_colors(content, format?, filename?, dedupe?, maxResults?) — finds colors and returns their spellings, normalized values, positions, and truncation metadata when applicable.

Recognized color syntax includes short and full hex values, comma-based and modern space-separated rgb() and hsl() forms, hwb(), lab(), lch(), oklab(), oklch(), color(), and CSS named colors such as rebeccapurple and transparent. HTML and SVG parsing also covers relevant style and color attributes.

Limitations and notes

Relative color syntax, calc(), and var() inside color functions are not parsed. Colors outside sRGB are clipped during conversion. Hex strings inside JavaScript strings, including URL fragments, can be detected. Stylus named colors require a value introduced with : or =. In raw-text scanning, a value segment extends to the end of its line, which can affect multiple tokens on one line. Alpha variants remain distinct colors rather than being merged with their opaque equivalents.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Colors Le

colors-le is an MCP server that connects MCP-compatible AI agents to the Colors-LE extraction engine. Its main tool, `extract_colors`, accepts source content and optionally a format or filename, then returns detected colors with their notation, normalized value, and 1-based line and column positions. It runs over stdio without reading files or making network requests.

Run it with `npx -y colors-le-mcp` and add that command to your host's MCP configuration. You can also install it globally with `npm install -g colors-le-mcp`, then configure the `colors-le-mcp` executable. The server needs no environment variables, API key, or additional configuration.

Yes, colors-le works with Cursor through the Open VSX extension or by configuring the MCP command `npx -y colors-le-mcp`.

It parses CSS, SCSS, LESS, Stylus, HTML, JavaScript, TypeScript, SVG/XML, JSON, JSONC, YAML, TOML, Markdown, and plain text. Other language IDs are processed as raw text and reported as `unknown`.

No, the MCP server only processes content supplied to its tool. It does not read files or make network requests of its own, so the calling agent or editor must provide the document content.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewColors Le AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/colors-le?style=directory)](https://allmcps.com/mcp/colors-le)
HTML Embed
<a href="https://allmcps.com/mcp/colors-le"><img src="https://allmcps.com/api/badge/colors-le?style=directory" alt="Colors Le on AllMCPs" /></a>