Icon MCP

io.github.pratham-jain33v0.1.0更新於 Oct 2, 2026

Lucide icon sets for AI: search 2000+ icons, style them, batch-export SVG. Offline, no key.

概覽

AI 產生的概覽

讓助理搜尋 2000 多個內建的 Lucide 圖示並產生帶樣式的 SVG 標記,離線執行且不需要 API 金鑰。

功能
提供兩個工具:search_icons 依名稱與標籤的關鍵字尋找圖示,generate_icons 將單一圖示或一整組相符的圖示算繪成帶樣式的 SVG 標記。描邊寬度、顏色、尺寸等樣式參數會套用到同一次呼叫中的所有圖示,因此回傳的整組圖示在視覺上保持一致。SVG 以標記形式回傳,助理可將其儲存到專案中。全部操作都在本機針對內建圖示集執行。
適用情境
適合助理在建構介面時需要真實圖示而非表情符號的情況,尤其是頁面需要一組風格一致的圖示時。也適合你大致知道想要什麼但不確定確切圖示名稱,或希望圖示產生在沒有網路的環境下也能運作的情況。
執行需求
以本機程序透過 stdio 執行。可用 uvx icon-mcp 或 pip install icon-mcp 安裝;需要 Python,不需要 Node.js 或 npx。不需要 API 金鑰、帳號、環境變數或網路存取,因為圖示集已內建在套件中。
安裝前請注意
該專案自稱非官方社群專案,並非由 Lucide 製作或與其關聯;內建的 Lucide 圖示集採用 ISC 授權。此伺服器只讀取內建圖示並回傳 SVG 標記,本身不會寫入、傳送或刪除資料;儲存回傳的 SVG 是由助理在你的專案中完成。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Icon MCP,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

icon-mcp

mcp-name: io.github.pratham-jain33/icon-mcp

[License: MIT] [Python 3.10+] [MCP Compatible] [Version] [PyPI]

Give any AI assistant a custom icon button. No emojis, no designer needed.

Unofficial community project. Not made by, endorsed by, or affiliated with Lucide. The Lucide icon set (ISC licensed) is bundled inside the package, so everything works offline.

Why

AI assistants reach for emojis when a UI needs an icon, because drawing a good icon is actual design work. This server plugs into any MCP-compatible assistant (Claude Desktop, Claude Code, Cursor, and more) and lets it search 2000+ Lucide icons by keyword, restyle them (stroke width, color, size), and generate a whole matching set in one call so every icon on the page looks like it belongs together. The SVGs come back as markup the assistant saves straight into the project. No API key, no account, no network.

Tools

ToolDescription
search_iconsFinds icons by keyword across names and tags. Use when you don't know the exact icon name.
generate_iconsRenders one icon or a whole matching set as styled SVG markup. Takes names or plain-words queries plus shared stroke_width, color, size.

Quickstart

Install

No cloning needed:

bash
uvx icon-mcp

or with pip:

bash
pip install icon-mcp

From source instead:

bash
git clone https://github.com/pratham-jain33/icon-mcpcd icon-mcppython -m venv .venv.venv/bin/pip install -e .

Connect your assistant

Claude Desktop config file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
json
{  "mcpServers": {    "icon-mcp": {      "command": "uvx",      "args": ["icon-mcp"]    }  }}

No environment variables, no keys. From source, point at your checkout instead:

json
{  "mcpServers": {    "icon-mcp": {      "command": "/absolute/path/to/icon-mcp/.venv/bin/python",      "args": ["-m", "icon_mcp.server"]    }  }}

Restart Claude Desktop, then try: "Find me a settings icon and a trash icon, both 1.5px stroke in #2f6bff at 32px, as SVGs."

Configuration

None. There is nothing to configure: no API keys, no accounts, no network access. The icon set ships inside the package.

How it works

  1. You ask the assistant for icons in plain words.
  2. The assistant calls search_icons to find the right names, or passes keywords straight to generate_icons.
  3. The server resolves each query to a bundled Lucide SVG and rewrites four attributes on it: width, height, stroke-width, stroke. Pure XML manipulation, no rendering, no native dependencies.
  4. Every icon in one call gets the identical style, so the set is visually consistent by construction.
  5. The server returns JSON with the SVG markup per icon; the assistant saves them as .svg files in your project.

Example session

You:    I need icons for my landing page nav: home, features, pricing,        contact. Make them all match: thin 1.5 stroke, blue #2f6bff.
Claude: [calls generate_icons with ["home", "features", "pricing",        "contact"], stroke_width=1.5, color="#2f6bff"]        Done. Four SVGs, all 1.5px stroke in #2f6bff, saved to icons/.        "features" resolved to the "sparkles" icon, "contact" to "mail".

Why icon-mcp instead of Unicon

Unicon is the closest existing tool: an MCP server over a hosted icon API with 19,000+ icons across 9 libraries. icon-mcp takes the opposite trade:

  • Fully offline. The whole set is bundled in the package. No hosted API, works on a plane.
  • No account, no tiers. Free forever, nothing to sign up for.
  • Python-native. Installs with uvx/pip; no Node or npx needed.
  • One-call consistent sets. Pass a list of icons plus one style; every SVG comes back matching. The style params (stroke width, color, size) are first-class, not an afterthought.
  • Smaller, calmer surface. Two tools, one library, zero config.

The trade: one library (Lucide) instead of nine, and keyword search instead of semantic search. For shipping a consistent icon set on a page, that's the whole job.

Parameters

generate_icons accepts:

ParameterDefaultRules
icons(required)1-50 names or keyword queries, e.g. ["home", "trash can"]
stroke_width2.00.5 to 4 (2 is Lucide's default)
color"currentColor"currentColor, hex (#2f6bff), or CSS name (red)
size241 to 1024 pixels

Queries that don't resolve are reported in the unresolved list instead of failing the whole call.

Roadmap

  • v0.1 — bundled Lucide set (v1.50.0), keyword search, parametric SVG styling, batch sets in one call
  • Website: paste a prompt, download a styled set
  • More libraries (Tabler, Heroicons) as opt-in bundles

Contributing

Issues and pull requests are welcome. If you add a tool, write its description the way you'd explain it to a smart friend who has never seen it — the assistant reads that text to decide when to use it. To refresh the icon bundle against a newer Lucide release, bump LUCIDE_VERSION in scripts/fetch_lucide.py and run it.

License

MIT © Pratham Jain. See LICENSE.

Acknowledgments

Built on Lucide's icon set (ISC licensed, see icon_mcp/LUCIDE_LICENSE) and the Model Context Protocol.

來源:README.md,提交 b4fc23b

工具

0
工具後設資料尚未被收錄。

版本歷史

1
  1. v0.1.0最新Oct 2, 2026