What is the Design System Extractor MCP server?
The Design System Extractor MCP server reads a Storybook design system for an AI coding agent. It lists and searches components, extracts rendered HTML and styles, maps component dependencies and pulls theme tokens such as colors, spacing and typography. You point it at your Storybook with the STORYBOOK_URL variable.
The Design System Extractor MCP server connects to a Storybook instance and extracts component information for an AI coding agent. It reads rendered HTML, styles and component metadata, and it works with built Storybook distributions.
A headless Chrome session through Puppeteer renders dynamic JavaScript components. The server runs on your machine, and the STORYBOOK_URL variable points it at your Storybook, with the local port 6006 as the default.
What it changes in your workflow
- Your agent lists and searches components by name, title, category or purpose, such as form inputs, navigation, feedback and buttons.
- It reads the rendered HTML of a story and its variants, so new code can match markup that already exists.
- It analyzes rendered HTML to find which other components a component uses, including React components, web components and CSS class patterns.
- It extracts theme information such as colors, spacing, typography, breakpoints and CSS custom properties.
- Long operations run as background jobs that the agent can poll, cancel and list.
Setup at a glance
| Design System Extractor MCP server | |
|---|---|
| Where it runs | On your machine, started with npx |
| Needs | A Storybook instance, plus Chrome or Chromium for Puppeteer |
| Main setting | STORYBOOK_URL, which points at your Storybook |
| Self-signed certificates | Set NODE_TLS_REJECT_UNAUTHORIZED to 0 |
Who it is for
Best for
- Teams with a Storybook who want agents to reuse the components they already have.
- Developers refactoring a codebase toward a design system and needing rendered HTML as a reference.
- Anyone who needs colors, spacing and typography tokens from a Storybook theme and its CSS.
Not for
- If you need to generate or update Storybook stories from your own design system components, Story UI MCP Server is the better fit for that.
- When the job is reading design tokens from any live URL instead of a Storybook, the designlang MCP server is the better fit for that.
- If your job is extracting real colors, typography and spacing from a live site, the Extract Design skill is the better fit for that.
- When the job is checking extracted design tokens for drift, Dembrandt MCP Server is the better fit for that.
Connect Design System Extractor MCP: Read Storybook Components to your AI client
claude mcp add design-system npx mcp-design-system-extractor@latest --env STORYBOOK_URL=http://localhost:6006Run the add command
The docs recommend the Claude CLI command above. Swap STORYBOOK_URL for the address of your own Storybook.
Or install with npm
Run npm install -g mcp-design-system-extractor, then configure your MCP client with STORYBOOK_URL in its env settings.
Self-signed certificate
Add NODE_TLS_REJECT_UNAUTHORIZED=0 as an env value when your Storybook uses a self-signed certificate.
From source
Clone the repo, run npm install and npm run build, then npm run setup for the interactive Claude Desktop setup.
Run a first call
Ask the agent to run list_components with compact set to true, then search_components with a query such as button.
Client configuration
{
"mcpServers": {
"design-system": {
"command": "node",
"args": ["/path/to/dist/index.js"],
"env": {
"STORYBOOK_URL": "https://my-storybook.example.com",
"NODE_TLS_REJECT_UNAUTHORIZED": "0"
}
}
}
}Endpoints and ports
claude mcp add design-system npx mcp-design-system-extractor@latestRegisters the server with Claude Code.STORYBOOK_URLDefaults to the local Storybook on port 6006.NODE_TLS_REJECT_UNAUTHORIZEDSet to 0 for self-signed certificates.What you can do with it
- Component listingLists every component in the Storybook with a compact mode that trims output, a category filter and paging.
- Purpose searchFinds components by name, title or category, or by what they do, for example form inputs or navigation.
- Rendered HTMLget_component_html returns the rendered HTML of a story, with an optional includeStyles flag for CSS and a variantsOnly flag for the list of variants.
- Dependency analysisDetects React components, web components and CSS class patterns used inside another component.
- Theme extractionget_theme_info reads colors, spacing, typography, breakpoints and CSS custom properties, with includeAll for every CSS variable.
- CSS token extractionget_external_css categorizes colors, spacing, typography and shadows. It accepts only URLs from the same domain as Storybook.
- Async job queueLong operations run in the background with job_status, job_cancel and job_list for tracking.
- Self-signed TLSAn environment setting lets the server reach a Storybook that uses a self-signed certificate.
Tools it exposes
list_components
Lists components from the Storybook. Supports compact output, a category filter and pagination with page and pageSize, default 20.
get_component_html
Extracts rendered HTML for a story. Async by default, with an async false option and a variantsOnly flag to list variants.
search_components
Searches by name, title, category or purpose, with searchIn and pagination options.
get_component_dependencies
Analyzes rendered HTML to find which other components a component uses.
get_theme_info
Extracts theme colors, spacing, typography, breakpoints and CSS custom properties.
get_external_css
Fetches and analyzes CSS from the same domain as Storybook. Returns design tokens and stats by default.
job_status
Checks the status of an async job and returns its result or error.
job_cancel
Cancels a queued or running job.
job_list
Lists jobs, filtered by all, active or completed, with queue statistics.
Frequently asked questions
What is the Design System Extractor MCP server?
It is an MCP server that connects to a Storybook instance and extracts component information for an AI coding agent. The agent can list components, read rendered HTML and styles, analyze dependencies and pull theme tokens.
How do I set up the Design System Extractor MCP server?
Run the claude mcp add command with npx mcp-design-system-extractor@latest and your STORYBOOK_URL. You can also run npm install -g mcp-design-system-extractor and configure your MCP client with the same environment variable, or build it from source.
Which AI coding agents work with the Design System Extractor MCP server?
The docs lead with the Claude CLI command and an interactive setup for Claude Desktop. A manual config entry that runs the server with node and STORYBOOK_URL set in env is also documented for other MCP clients.
Does it need a running Storybook?
Yes. It connects to a Storybook instance through STORYBOOK_URL, which defaults to the local port 6006, and it works with built Storybook distributions. Puppeteer with Chrome or Chromium renders dynamic JavaScript components so the extracted HTML reflects the rendered result.
How does it return component HTML?
get_component_html is asynchronous by default. It returns a job ID that you poll with job_status. Set async to false for a synchronous call with a timeout, or use variantsOnly to get the list of variants quickly.
Can it read design tokens from CSS?
Yes. get_external_css fetches and analyzes CSS and returns design tokens such as colors, spacing, typography and shadows with stats. Full CSS is returned only when includeFullCSS is true, and only URLs from the same domain as Storybook are accepted.
How do I connect to a Storybook with a self-signed certificate?
Set NODE_TLS_REJECT_UNAUTHORIZED to 0 as an environment value next to STORYBOOK_URL. The docs show this both in the claude mcp add command with an env flag and in the JSON config example.


