Uniform MCP Server

This guide explains how to get started with Uniform MCP Server. If you are unfamiliar with MCP Server, please take a look at the MCP docs.

Uniform MCP Server allows any MCP client (Cursor, Windsurf, Claude , etc.) to use Uniform API to create and manage developer artifacts like components and content types. This capability accelerates development and significantly reduces iteration loops.

AI Credits Required

Create, edit, and search operations for compositions, entries, and patterns performed through the MCP Server require AI Credits in your Uniform Team. All other MCP tools do not consume credits.

If you have already used all your existing credits you can request additional credits.

The Uniform MCP Server supports 21 tools, allowing for list, get, and create operations on the following Uniform entities:

  1. component definitions
  2. component patterns
  3. content types
  4. compositions πŸ†•
  5. entries πŸ†•
  6. entry patterns πŸ†•

The Uniform MCP Server enables you to manage your entire Uniform project through natural language interactions with your AI coding assistant. You can create, update, list, and retrieve components, content types, compositions, entries, and patterns without leaving your development environment. This streamlined workflow allows you to rapidly prototype new features, maintain consistency across your component library, and reduce context switching between your code editor and the Uniform dashboard.

You will need a team admin access level to your Uniform project to get started.

The easiest way to set up the Uniform MCP Server is to use the Uniform CLI. This method supports both Cursor and Claude Code:

npx @uniformdev/cli@latest ai mcp install

This command will automatically configure the MCP Server for your project. Follow the prompts to enter your Uniform project details.

If you prefer to set up the MCP Server manually or need a custom configuration, follow the instructions below.

  1. Go to your team's /security/api-keys section.
  2. Create a new API key with Developer role assigned to your project.
  3. Click on the chevron icon next to "Copy as .env" and select "Copy as mcp json" option.
mcp-json
Create MCP json

Next, you need to create a mcp.json file, which will look like this:

{ "mcpServers": { "Uniform": { "type": "stdio", "command": "npx", "args": [ "-y", "@uniformdev/uniform-mcp" ], "env": { "UNIFORM_API_KEY": "your-api-key", "UNIFORM_PROJECT_ID": "your-project-id", "UNIFORM_AI_API_HOST": "https://ai.uniform.global" } } } }

The location depends on your MCP client of choice.

For example, for Cursor, you will need to create a mcp.json in the .cursor folder within the root of your project.

Paste the JSON you copied in the previous step into the mcp.json file.

Afterwards, Cursor will prompt you to add the MCP Server to your project:

mcp-server-detected
Add MCP Server

This also depends on your MCP client. In Cursor, open Cursor Settings, go to Tools & Integrations, and see the Uniform MCP server. The icon should be green if the MCP Server is running.

cursor-settings
MCP Server in Cursor Settings

Troubleshooting

If the icon is either red or yellow, reopen this settings screen after restarting Cursor.

For Claude Code, you can add mcp.json to the root of your project or add it via the Claude command line (see docs for more). Check the official documentation of your MCP client for more details.

Now you can test the MCP Server by running the following command in your MCP client prompt:

create a hero component with title and description field (rich text).

Voila! You should see something similar to this reply:

cursor-response
MCP Server in Cursor

This indicates that Cursor called componentAction function and inspected the payload as well as the response:

mcp-response
MCP Server response in Cursor

Now, if you open your Uniform project's component library, you should see the new component you just created:

new-component-created
New component created.

Follow these best practices to achieve reliable, high-quality results when working with the MCP Server:

By default, LLM's knowledge of Uniform will be limited to what was indexed by LLM using the public internet and subject to the cutoff date. It is highly recommended that you feed uniform-specific AI rules into your LLM context to enhance your prompting with the latest knowledge of Uniform.

You can head over to the AI rules guide to learn how to use AI rules to enhance your dev experience.

After making structural changes through the MCP Server, use the sync command to ensure your local project files stay up to date. Our AI rules provide instructions on maintaining regular synchronization.

Once you have synced your project, you should regularly commit your exported Uniform files to Git. This will give you a clear history of updates over time and make it easy to roll back changes if needed.

If you have made updates to Uniform entities such as components or content types directly in the Uniform dashboard, make sure to ask the MCP to reload the latest version before proceeding with any additional changes. This will keep the AI’s context up to date and help prevent overwriting recent updates.

Provide clear, specific prompts instead of broad, ambiguous requests. For complex workflows, break them down into smaller, focused tasks that the AI can handle more accurately. Many AI-assisted editors include planning features that help decompose large tasks into manageable stepsβ€”use these tools to create a structured approach before making changes through the MCP Server. Keep chats concise and focused on the current task. Start new chats to clear context when starting a new task.

After the AI creates or modifies components, content types, or other entities through the MCP Server, review the results in your Uniform project. AI assistants can misinterpret instructions or make mistakes, so it's important to verify that the generated structures match your expectations before using them in production.

You can use multiple MCP servers together to handle specialized tasks in your workflow.

For example:

  • Figma MCP β€” generate React components from Figma designs
  • Context7 MCP β€” query up-to-date documentation for code libraries
  • Storybook MCP β€” retrieve information about components in your design system

manage your active mcp tools

AI editors support only a limited number of MCP tools at the same time, so you may need to enable or disable specific MCP servers based on what you're trying to accomplish.