# cursor-talk-to-figma-mcp

> MCP Client

This repository provides a Model Context Protocol (MCP) integration between Cursor AI and Figma, enabling Cursor to read and programmatically modify Figma designs through a WebSocket server and a Figma plugin.

## Overview

- **Category:** Developer Tools
- **Language:** JavaScript
- **Stars:** 6938
- **Forks:** 168
- **Owner:** sonnylazuardi
- **GitHub:** https://github.com/sonnylazuardi/cursor-talk-to-figma-mcp
- **Homepage:** https://x.com/sonnylazuardi/status/1901325190388428999
- **Created:** 2025-03-16T16:45:37+00:00
- **Updated:** 2025-03-28T23:56:34+00:00
- **Source:** https://model-context-protocol.com/clients/cursor-ai-figma-design-integration

## Setup

## Setup

1. Install Bun if you haven't already:

```bash
curl -fsSL https://bun.sh/install | bash
```

2. Run setup, this will also install MCP in your Cursor's active project

```bash
bun setup
```

3. Start the Websocket server

```bash
bun socket
```

4. MCP server

```bash
bunx cursor-talk-to-figma-mcp
```

5. Install [Figma Plugin](#figma-plugin)

## Tools

## Available Tools

1. `get_document_info` - Get information about the current Figma document
2. `get_selection` - Get information about the current selection
3. `get_node_info` - Get detailed information about a specific node
4. `get_nodes_info` - Get detailed information about multiple nodes by providing an array of node IDs
5. `create_rectangle` - Create a new rectangle with position, size, and optional name
6. `create_frame` - Create a new frame with position, size, and optional name
7. `create_text` - Create a new text node with customizable font properties
8. `set_text_content` - Set the text content of an existing text node
9. `set_fill_color` - Set the fill color of a node (RGBA)
10. `set_stroke_color` - Set the stroke color and weight of a node
11. `set_corner_radius` - Set the corner radius of a node with optional per-corner control
12. `move_node` - Move a node to a new position
13. `resize_node` - Resize a node with new dimensions
14. `delete_node` - Delete a node
15. `clone_node` - Create a copy of an existing node with optional position offset
16. `get_styles` - Get information about local styles
17. `get_local_components` - Get information about local components
18. `get_team_components` - Get information about team components
19. `create_component_instance` - Create an instance of a component
20. `export_node_as_image` - Export a node as an image (PNG, JPG, SVG, or PDF)
21. `execute_figma_code` - Execute arbitrary JavaScript code in Figma (use with caution)
22. `join_channel` - Join a specific channel to communicate with Figma
