TalkToFigma
TalkToFigma connects a local AI agent (Claude Code, Cursor, etc.) to Figma's Plugin API through a localhost WebSocket relay (port 3055), giving it full read/write control of a Figma document with no REST API, no official MCP server, and no call limits.
Inspect the document, current selection, one or many nodes, styles, local components, variable collections/variables, annotations, fonts, prototype reactions, and scanned text nodes or nodes by type.
Create rectangles, frames, text, empty components (with Auto Layout params), components from existing nodes, and instances of local or published library components.
Edit style: fill/stroke colors, stroke weight, corner radius (with per-corner control), text content (single or bulk), typography (font family/style/size, line height, letter spacing, alignment, case, decoration, auto-resize), effects such as drop shadows and blurs, and content clipping.
Layout: set Auto Layout mode/wrap, padding, item and counter-axis spacing, primary/counter axis alignment, and FIXED/HUG/FILL sizing.
Arrange and transform: move, resize, clone, delete (single or bulk), reparent nodes (set_parent with index/keepPosition), reorder children, rename layers, focus/select nodes, and create, switch, or move nodes between pages.
Variables and tokens: list collections and variables, create collections with modes, create COLOR/FLOAT/STRING/BOOLEAN variables (slash-grouped names), and bind variables to fills, strokes, size, radius, padding, spacing, stroke weight, opacity, and text properties.
Annotate and prototype: get/set annotations (single or batch) and read reactions to build FigJam-style connector lines with a default connector style.
Export nodes as PNG/JPG/SVG/PDF, optionally writing large images straight to a file, and dump a node/page's real layout, tokens, and provenance to disk.
Build whole screens: plugin-side build_tree / ensure_tokens / combine_variants / clear_page, plus scripts that extract a running web app with Playwright and rebuild it in Figma with variants, variables, and styles, then visual-diff and run a compliance check.
Target a file: join_channel pairs the agent with a specific Figma plugin instance/file so commands reach only the intended document.
Allows AI agents to generate and edit Figma designs locally via the Figma Plugin API, without API limits or external communication.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@TalkToFigma create a frame named 'Login' with width 400 and height 300"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Figma Local Bridge
ローカルで動くAIエージェント(Claude Code、Cursor、その他)が、Figma Plugin APIを通じてFigmaデザインを生成・編集できるようにします。Figma REST APIも公式のFigma MCPサーバーも使わず、コール数の制限もありません。すべてlocalhostで完結します。
Why
公式のFigma MCPサーバーは有料シートが必要で、コール数にも制限があります。Figma Local Bridgeは代わりにPlugin API(追加コストなし、Figmaエディタ内で動作)をローカルのWebSocketリレー経由で操作することで、AIエージェントに同等のプログラム的なキャンバス操作権限を与えます。通信はすべてローカルマシン内で完結し、外部通信は一切発生しません。
Related MCP server: mcp-figma
Architecture
MCP server (bun) <--> WebSocket relay :3055 <--> Figma plugin <--> Plugin APIMCP server — Model Context Protocol経由でAIエージェントにデザインツールを公開します。
WebSocket relay — MCPサーバーとFigmaプラグインを名前付きチャンネルで接続する、localhost限定のブリッジ(ポート3055)です。
Figma plugin — Figmaエディタ内で動作し、Plugin APIに対してコマンドを実行します。
Quick start
Bunをインストールし、依存関係をインストールします。
bun installWebSocketリレーを起動します。
bun run src/socket.tsFigmaデスクトップアプリでプラグインをインポートします。 Plugins → Development → Import plugin from manifest… →
src/cursor_mcp_plugin/manifest.jsonを選択。AIエージェント(例: Claude Code)にMCPサーバーを登録します。同梱の
.mcp.jsonはサーバーを直接起動します。{ "mcpServers": { "TalkToFigma": { "command": "bun", "args": ["src/talk_to_figma_mcp/server.ts"] } } }Figmaでプラグインを実行し、Connectをクリックします。デフォルトのチャンネルは
figma-local-bridgeです(プラグインのConnectionタブで編集可能、リロード後も保持されます)。その後、エージェントに同じチャンネル名でjoin_channelを呼び出させます。
Tools
MCPサーバーは、Figmaデザインの読み取り・編集のためのツールを公開しています。ドキュメント/選択状態の検査、フレーム・矩形・テキストの作成、オートレイアウトと間隔設定、塗り/線/角丸、移動・リサイズ・複製・削除、コンポーネントとインスタンスのオーバーライド、アノテーション、プロトタイプのリアクション、FigJamコネクタ、画像エクスポートなどです。
このforkで追加した9個のツール
set_parent— ノードを別のノードの子として再配置します(インデックス/位置維持を指定してappend childを実行)。reorder_children— 親ノード内の子要素の並び順を変更します。set_text_style— テキストノードの行間・字間・配置・フォントファミリー/スタイルを設定します。get_variables— ローカル変数を一覧表示します(コレクションでのフィルタも可能)。create_variable_collection— モード名を指定して変数コレクションを作成します。create_variable— スラッシュ階層の名前を持つCOLOR/FLOAT/STRING/BOOLEAN変数を作成します。bind_variable— 変数をノードのプロパティ(fills、strokes、サイズ、角丸、パディング、間隔など)にバインドします。create_component_from_node— 既存のノードをコンポーネントに変換します。create_component— オートレイアウトのパラメータと任意の名前を指定して空のコンポーネントを作成します。
その後に追加したツール
set_effect/set_clips_content— 影(DROP_SHADOW など)と「コンテンツを隠す」の切り替え。dump_tree— ノード(省略時は現在のページ)の実際のレイアウト(Auto Layout の向き・余白・間隔・サイズの決め方・変数の結び付け・テキストスタイル・出典の記録)を読み出します。outputPathでファイルに書けます。ensure_pages/set_current_page/move_to_page— ページの作成・切り替え・ページ間の移動。rename_node/list_fonts— レイヤー名の変更、フォントの太さの一覧。export_node_as_imageにoutputPathを追加しました(大きな画像を会話に流さずファイルに保存)。
プラグインには、スクリプトから使う build_tree(画面を丸ごと一度に組み立てる)、ensure_tokens(色変数・テキストスタイル・エフェクトスタイルの登録)、combine_variants、clear_page もあります。
動いているWebアプリからFigmaを組み立てる
scripts/ のスクリプトで、実際の表示を測ってそのまま Figma に起こせます(Playwright の Chromium が必要)。
node scripts/dom-extract.mjs --base http://localhost:5173 --out <dir> --screens screens.json --components <React部品名,...>— 各画面を 375px / 1366px で開き、要素の箱・計算済みスタイル・文字・画像・SVG と画面写真を保存します。node scripts/figma-build.mjs --expect-file <ファイル名> --extract <dir> --screens screens.json --images <public/images> --src <app/src> --out manifest.json --components <部品名,...> [--state-components StatusBadge:Status] [--variant-labels "TodoItem=未完了|完了"] [--clean]— Auto Layout・コンポーネント(画面幅や状態のバリアント)・色変数・テキストスタイル・エフェクトスタイルで組み立てます。各ノードには元の要素と寸法の出典が記録されます。--expect-fileは必須です。プラグインが1つだけ、そのファイルで動いている時にだけ書き込みます(get_file_infoを全プラグインに問い合わせて確かめます)。--variant-labelsは、同じ部品でも構造が違う使われ方(チェック済みのタスクなど)を、使われる数の多い順に「状態」のバリアントにします。--layout courseは講座のファイルの形式(コンポーネント枠・スタイルガイド枠・SP/PC の組)で並べます。--component-labels、--components-note、--style-guide、--ogpで見出しや中身を指定します。スクリプトは環境変数
FIGMA_TARGET_FILE=<ファイル名>を付けて動かすと、別のファイルで開いているプラグインに命令が届きません(プラグインは宛先が違う命令に応えません)。
node scripts/figma-export.mjs manifest.json <dir>とpython3 scripts/visual-diff.py <実画面.png> <Figma.png> <比較.png>— 実画面と見比べます。node scripts/compliance-check.mjs --manifest manifest.json— 余白10px帯・出典のない固定サイズ・FILLの付け忘れ・縮む親の中のFILL・切れる影・変数の結び忘れ・テキストスタイル・既定のレイヤー名・画面の高さを検査します。
同梱のClaude Codeスキル
Claude Codeスキルが.claude/skills/talk-to-figma-design/に含まれています。Plugin APIの制約、呼び出し順序、トークン節約のルール、エージェント駆動のFigma操作を信頼性高く動かすためのデザイン品質のデフォルト設定をまとめています。
Credits
cursor-talk-to-figma-mcp(Sonny Lazuardi作、MIT)をベースに変更を加えています。LICENSEを参照してください。
Disclaimer
非公式です。Figma社とは一切関係なく、承認や推奨も受けていません。
Available Tools
50 toolsbind_variableA
Bind a variable to a node property. property 'fills' or 'strokes' binds the first solid paint's color (setBoundVariableForPaint). Other properties (width, height, cornerRadius, top/bottom/left/right radius, padding*, itemSpacing, counterAxisSpacing, strokeWeight, opacity, min/maxWidth, min/maxHeight, and text fields fontSize/fontWeight/lineHeight/letterSpacing/paragraphSpacing/paragraphIndent) use node.setBoundVariable. Variable type must match the property.
Inputs: nodeId (required), property (required), variableId (required).
clone_nodeC
Clone an existing node in Figma
Inputs: nodeId (required), x, y.
create_componentA
Create a new empty component. Supports the same Auto Layout parameters as create_frame. Returns the component's ID for use as a parentId or with create_component_instance.
Inputs: x (required), y (required), width (required), height (required), +16 more.
create_component_from_nodeA
Convert an existing node into a component (figma.createComponentFromNode). The node cannot already be a component, component set, or instance, nor be nested inside one. Returns the new component's ID.
Inputs: nodeId (required).
create_component_instanceA
Create an instance of a component in Figma. For LOCAL components (from get_local_components), use componentId with the id field. For published LIBRARY components, use componentKey with the publishedKey field.
Inputs: x (required), y (required), parentId, componentId, +1 more.
create_connectionsB
Create connections between nodes using the default connector style
Inputs: connections (required).
create_frameC
Create a new frame in Figma
Inputs: x (required), y (required), width (required), height (required), +16 more.
create_rectangleC
Create a new rectangle in Figma
Inputs: x (required), y (required), width (required), height (required), +2 more.
create_textC
Create a new text element in Figma
Inputs: x (required), y (required), text (required), name, +4 more.
create_variableA
Create a variable inside a collection, optionally seeding per-mode values. COLOR values are { r, g, b, a } (0-1). Get modeIds from get_variables or create_variable_collection.
Inputs: name (required), collectionId (required), resolvedType (required), valuesByMode.
create_variable_collectionA
Create a local variable collection. Optionally provide mode names; the first renames the default mode and the rest are added.
Inputs: name (required), modes.
delete_multiple_nodesB
Delete multiple nodes from Figma at once
Inputs: nodeIds (required).
delete_nodeC
Delete a node from Figma
Inputs: nodeId (required).
export_node_as_imageC
Export a node as an image from Figma
Inputs: nodeId (required), scale, format.
get_annotationsB
Get all annotations in the current document or specific node
Inputs: nodeId (required), includeCategories.
get_document_infoA
Get detailed information about the current Figma document
Inputs: no named parameters.
get_instance_overridesA
Get all override properties from a selected component instance. These overrides can be applied to other instances, which will swap them to match the source component.
Inputs: nodeId.
get_local_componentsA
Get all local components from the Figma document
Inputs: no named parameters.
get_node_infoB
Get detailed information about a specific node in Figma
Inputs: nodeId (required).
get_nodes_infoC
Get detailed information about multiple nodes in Figma
Inputs: nodeIds (required).
get_reactionsA
Get Figma Prototyping Reactions from multiple nodes. CRITICAL: The output MUST be processed using the 'reaction_to_connector_strategy' prompt IMMEDIATELY to generate parameters for connector lines via the 'create_connections' tool.
Inputs: nodeIds (required).
get_selectionB
Get information about the current selection in Figma
Inputs: no named parameters.
get_stylesA
Get all styles from the current Figma document
Inputs: no named parameters.
get_variablesA
List local variable collections (with their modes) and variables (id, name, resolvedType, valuesByMode). Optionally filter to a single collection.
Inputs: collectionId.
join_channelC
Join a specific channel to communicate with Figma
Inputs: channel.
move_nodeC
Move a node to a new position in Figma
Inputs: x (required), y (required), nodeId (required).
read_my_designA
Get detailed information about the current selection in Figma, including all node details
Inputs: no named parameters.
reorder_childrenA
Change the order of a child node within its parent's children array by moving it to a new index
Inputs: nodeId (required), newIndex (required), parentId (required).
resize_nodeC
Resize a node in Figma
Inputs: width (required), height (required), nodeId (required).
scan_nodes_by_typesC
Scan for child nodes with specific types in the selected Figma node
Inputs: types (required), nodeId (required).
scan_text_nodesC
Scan all text nodes in the selected Figma node
Inputs: nodeId (required).
set_annotationB
Create or update an annotation
Inputs: nodeId (required), labelMarkdown (required), categoryId, properties, +1 more.
set_axis_alignA
Set primary and counter axis alignment for an auto-layout frame in Figma
Inputs: nodeId (required), counterAxisAlignItems, primaryAxisAlignItems.
set_corner_radiusA
Set the corner radius of a node in Figma
Inputs: nodeId (required), radius (required), corners.
set_default_connectorB
Set a copied connector node as the default connector
Inputs: connectorId.
set_effectA
Replace all effects on a node with the provided list (assigns node.effects). Pass effects:[] to clear every effect. SHADOW effects use color/offset/radius/spread; BLUR effects use only radius. Fails clearly if the node does not support effects.
Inputs: nodeId (required), effects (required).
set_fill_colorC
Set the fill color of a node in Figma can be TextNode or FrameNode
Inputs: b (required), g (required), r (required), nodeId (required), +1 more.
set_focusA
Set focus on a specific node in Figma by selecting it and scrolling viewport to it
Inputs: nodeId (required).
set_instance_overridesA
Apply previously copied overrides to selected component instances. Target instances will be swapped to the source component and all copied override properties will be applied.
Inputs: targetNodeIds (required), sourceInstanceId (required).
set_item_spacingA
Set distance between children in an auto-layout frame
Inputs: nodeId (required), itemSpacing, counterAxisSpacing.
set_layout_modeB
Set the layout mode and wrap behavior of a frame in Figma
Inputs: nodeId (required), layoutMode (required), layoutWrap.
set_layout_sizingA
Set horizontal and vertical sizing modes for an auto-layout frame in Figma
Inputs: nodeId (required), layoutSizingVertical, layoutSizingHorizontal.
set_multiple_annotationsC
Set multiple annotations parallelly in a node
Inputs: nodeId (required), annotations (required).
set_multiple_text_contentsB
Set multiple text contents parallelly in a node
Inputs: text (required), nodeId (required).
set_paddingB
Set padding values for an auto-layout frame in Figma
Inputs: nodeId (required), paddingTop, paddingLeft, paddingRight, +1 more.
set_parentA
Move a node so it becomes a child of another node (reparent). Uses appendChild, or insertChild when an index is given. Works with Auto Layout parents. Set keepPosition to preserve the node's absolute position (ignored for auto-layout parents).
Inputs: nodeId (required), parentId (required), index, keepPosition.
set_selectionsA
Set selection to multiple nodes in Figma and scroll viewport to show them
Inputs: nodeIds (required).
set_stroke_colorB
Set the stroke color of a node in Figma
Inputs: b (required), g (required), r (required), nodeId (required), +2 more.
set_text_contentA
Set the text content of an existing text node in Figma
Inputs: text (required), nodeId (required).
set_text_styleA
Set detailed typography on a TEXT node in one call. Only the provided fields are applied. Font is loaded automatically before changes. lineHeight/letterSpacing accept an object with value+unit ({unit:'AUTO'} for lineHeight auto).
Inputs: nodeId (required), fontSize, textCase, fontStyle, +7 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 50 tools
Most tools map to distinct resource-action pairs, reducing ambiguity. However, 'read_my_design' overlaps heavily with 'get_selection', and 'scan_text_nodes' vs 'scan_nodes_by_types' share boundaries. Descriptions help clarify, but a few tools could be confused.
The vast majority follow a clear snake_case verb_noun pattern (get_, set_, create_). The outliers are 'read_my_design' (uses 'read' instead of 'get') and 'join_channel' (a non-design operation), but overall the convention is predictable.
At 50 tools, the server far exceeds the typical coherent range. Many tools are extremely specific (e.g., set_layout_sizing, set_item_spacing) and could be consolidated with related set* operations without sacrificing functionality. The count feels bloated and increases selection difficulty.
The toolset provides comprehensive coverage for Figma's core workflows: CRUD on nodes, styling, layout, components, variables, annotations, and export. Minor gaps exist (e.g., no vector/shape creation beyond rectangles, no direct text retrieval), but these are workable for most design automation tasks.
Maintenance
Related MCP Connectors
Design canvas for agents: create, edit, render and export Figma-shaped designs over MCP.
Serves your design system and coding standards to coding agents, so they stop guessing.
Let AI agents use any website you're logged in to. Sessions stay encrypted on your machine.
Agent-Native design tool - create and edit visual designs with agent assistance
Related MCP Servers
- AlicenseNot gradedqualityNot gradedmaintenanceEnables AI agents like Claude to interact with Figma designs through 50+ tools for creating, styling, and manipulating design elements, components, and variables via a WebSocket relay and Figma plugin.-
- AlicenseNot gradedqualityDmaintenanceBridges AI clients to Figma Desktop via Plugin API and WebSocket, enabling real-time design manipulation without rate limits.826 npmMIT
- AlicenseNot gradedqualityCmaintenanceConnects AI agents to Figma through a local WebSocket bridge, enabling read/write access to open Figma files, node manipulation, and AI-assisted rename/group features.6MIT
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to read and write Figma designs through a local WebSocket relay, turning Figma selections into framework-aware code and building/editing designs directly on the canvas. Provides 112 MCP tools for bidirectional design-code workflows with support for any MCP client.MIT