Figme

io.github.ntson9p由 GitHub 账号 ntson9p 发布v1.1.1更新于 Oct 24, 2026

MCP server that reads local Figma .fig files, fully offline

概览

AI 生成的概览

离线读取本地 Figma .fig 文件,让助手查看图层、样式、组件、设计变量和图片,并把画框渲染成 PNG 或 SVG。

可以做什么
  • 汇总文件概况:页面、节点数量、组件、变量与图片数量
  • 查看结构:图层树、单个图层的尺寸与位置、按名称或文字搜索图层
  • 检查样式:填充、描边、效果、排版、以 CSS flexbox 表示的自动布局,以及设计变量
  • 查看组件与实例,包括实例相对组件做了哪些改动
  • 提取内嵌图片与缩略图,或读取原始矢量数据
  • 把任意图层或页面渲染为 PNG 或 SVG
适用场景
适合让助手依据本地保存的 .fig 设计稿编写或核对界面,例如把某个画框转成组件、把颜色变量转成 CSS 自定义属性。也适合没有 Figma 账号或 API 令牌的离线场景。
运行要求
通过 npx 以 stdio 在本地运行,需要 Node.js 22.15 或更高版本。需先在 Figma 中把设计另存为 .fig 文件,并向助手提供完整路径。无需账号、令牌或网络。
安装前请注意
对 .fig 文件本身只读,但 fig_image 和 fig_render 在要求时会写出文件。大文件占用内存较多:39 MB 的文件解析后约需 900 MB 内存,默认最多缓存 4 个已解析文件。渲染会近似部分效果并跳过另一些效果,其他文件发布的组件或变量只显示为引用。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Figme,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

figme

An MCP server that lets your AI agent read Figma .fig files — offline, with no Figma account or API token.

[npm] [Node.js] [License: MIT]

Save a design from Figma as a .fig file, and your agent can read everything in it: layers and layout, colours, text, components, design tokens and images. figme can also draw any frame as a picture, so the agent can compare what it built with the design.

you: "what does the tab component in design.fig look like?"
fig_overview  → 10 pages, 2,046 components, 273 variables, 212 imagesfig_find      → "lv2/tab/large" is 2:1337, on page "Page 1"fig_style     → display:flex, direction:row, gap:8, padding:"8px 16px",                cornerRadius:4, stroke #FFFFFF bound to variable "tab/large/underline"                (active #FFFFFF / inactive #333333)

Why figme

  • No account, token or network. figme reads the file on your disk and never contacts figma.com.
  • Everything in the file. Layers and geometry, auto-layout, fills, strokes, effects, text with mixed styles, components and instances, variables, prototype links and images. Layout comes back as CSS flexbox, colours as hex, and colours bound to variables keep their token names.
  • What Figma shows, not just what it stores. The layers inside a component instance come back with the instance's overrides applied, under the ids Figma itself gives them, and a shared style reports its live value rather than the stale copy cached beside it.
  • Pictures as well as numbers. fig_render draws any layer as a PNG or SVG.
  • Small responses. Even on a 116,000-node file, a response stays around 20 KB. Results are shallow by default, filterable and paged.
  • Robust to Figma updates. Every .fig carries the schema that describes it, and figme decodes the file with that schema, so fields Figma adds later don't break it.

Quick start

You need Node.js 22.15 or newer.

1. Save the design as a .fig file. In Figma, choose File → Save local copy… If it's a Community file, click Open in Figma first.

2. Add figme to your agent. In Claude Code:

bash
claude mcp add figme -- npx -y figme-mcp

For Cursor, VS Code, Windsurf and other clients, see Set up your client.

3. Ask. Give the full path to the file, and paste a Figma link if you have one:

Using figme, read /Users/me/Desktop/App.fig and build this frame as a React component: https://www.figma.com/design/AbC123/App?node-id=3017-121

The agent picks the tools from there. A few more things to try:

  • "List the pages and the most-used components in /Users/me/Desktop/App.fig."
  • "Turn the colour variables in /Users/me/Desktop/App.fig into CSS custom properties."
  • "Render the sign-in screen in /Users/me/Desktop/App.fig to /Users/me/Desktop/sign-in.png."

Set up your client

Every client runs the same command, npx -y figme-mcp. Only the place you put it changes.

Claude Code
bash
claude mcp add figme -- npx -y figme-mcp           # this projectclaude mcp add -s user figme -- npx -y figme-mcp   # every project

To share the server with everyone who works on a repository, commit a .mcp.json at its root:

json
{  "mcpServers": {    "figme": { "command": "npx", "args": ["-y", "figme-mcp"] }  }}

The Claude Code extensions for VS Code and JetBrains use this same configuration. They don't read the editor's own MCP settings.

Cursor

Add this to ~/.cursor/mcp.json for every project, or to .cursor/mcp.json for one:

json
{  "mcpServers": {    "figme": { "command": "npx", "args": ["-y", "figme-mcp"] }  }}
VS Code (GitHub Copilot)

From a terminal:

bash
code --add-mcp '{"name":"figme","command":"npx","args":["-y","figme-mcp"]}'

Or add this to .vscode/mcp.json. VS Code uses the key servers, not mcpServers:

json
{  "servers": {    "figme": { "type": "stdio", "command": "npx", "args": ["-y", "figme-mcp"] }  }}

Then switch the Chat view to Agent mode.

Windsurf

Add this to ~/.codeium/windsurf/mcp_config.json:

json
{  "mcpServers": {    "figme": { "command": "npx", "args": ["-y", "figme-mcp"] }  }}
Other clients

Any client that can start a local (stdio) MCP server works. Give it:

json
{ "command": "npx", "args": ["-y", "figme-mcp"] }

Config file locations change between client releases. If a path above doesn't match what you see, check your client's MCP documentation.

On Windows, some clients can't find npx by themselves. If the server doesn't start, run it through cmd:

json
{ "command": "cmd", "args": ["/c", "npx", "-y", "figme-mcp"] }

Tips

  • Always give the full path to the file, even with a link. A Figma link can't tell figme which file on your disk it belongs to, and a relative path is resolved from wherever your client started the server.

  • Don't let the agent open the Figma link. The page needs a login, so the agent gets nothing useful back, and it may then invent a design from the words in the URL. figme tells agents not to; if yours tries anyway, stop it.

  • "Node not found" usually means the saved file isn't the one the link points to. Compare the document name that fig_overview reports with the name in the link, or ask the agent to find the layer by name instead.

  • Big files need memory. A 39 MB .fig takes about 900 MB of RAM once parsed, and figme keeps up to 4 parsed files. On a smaller machine, keep just one:

    json
    { "command": "npx", "args": ["-y", "figme-mcp", "--max-files", "1"] }

Tools

Your agent picks these on its own; you don't need to name them.

ToolWhat it gives the agent
fig_overviewThe pages, node counts, and how many components, variables and images the file has
fig_treeThe layer tree under a node, a few levels at a time, instances opened
fig_nodeOne layer in detail: size, position, corner radii, auto-layout, children
fig_findLayers whose name or text contains a string
fig_textAll the text, with fonts and mixed styles
fig_styleFills, strokes, effects and typography, with auto-layout as CSS flexbox
fig_componentsThe components, their properties, and how often each is used
fig_instanceWhat an instance changes from its component
fig_variablesDesign tokens: every collection, mode and value
fig_imageEmbedded images, and the file's thumbnail
fig_blobRaw vector data, for anything the other tools don't decode
fig_renderA PNG or SVG picture of any layer or page

Parameters and example responses for each are in docs/tools.md.

Limitations

  • Read-only. figme never changes your .fig. It writes a file only when you ask fig_image or fig_render to save one.
  • A snapshot, not a live link. A .fig holds the design as it was when you saved it. When the design changes, save it again; figme picks up the new file.
  • Rendering is close, not pixel-perfect. fig_render approximates a few effects, such as background blur and angular gradients, and skips a few things, such as emoji. Every render lists what it approximated or skipped. See docs/rendering.md.
  • Libraries from other files aren't included. Styles, variables and components published from another file show up as references, without their values.
  • Vector paths aren't decoded. fig_blob returns their raw bytes.

Contributing

Issues and pull requests are welcome. CONTRIBUTING.md explains how to build from source and run the tests, and how the parser works.

License

MIT

来源:README.md,提交 3c6ab58

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v1.1.1最新Sep 21, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分