What is the Lovable MCP server?
Lovable exposes itself as a Model Context Protocol (MCP) server athttps://mcp.lovable.dev. This lets an AI client manage your Lovable projects through natural language.
When connected, your AI agent can create projects, send messages to Lovable, inspect code, deploy apps, and more, all without leaving the client you’re already working in. The Lovable MCP server is available on all plans.
What MCP is
MCP (Model Context Protocol) is an open standard that lets AI agents discover and call external tools. When an agent connects to an MCP server, it can see what tools are available and decide when to use them. Lovable’s MCP server makes Lovable one of those tools: findable, invokable, and composable.Supported AI clients
The Lovable MCP server’s OAuth flow is currently restricted to the following clients:- ChatGPT
- Claude (Claude Desktop on macOS and Windows, and claude.ai)
- Claude Code
- Cursor
- VS Code
The flow
- An agent connects to the Lovable MCP server
- The agent calls a tool (for example,
create_project) with a description of what to build - Lovable builds the project and returns a preview URL
- You can open the preview, review what was built, and continue iterating by sending more messages
- The agent keeps building as you refine, adding features, fixing issues, and changing the design
- When you’re happy with it, publish with
deploy_project. Or don’t, publishing is always optional.
Who this is for
- Developers using ChatGPT, Claude Code, Cursor, or VS Code who want to spin up and iterate on Lovable projects without leaving their AI client or editor
- Teams who want Lovable as a step in a larger agent flow: generate content, scaffold a UI, deploy it, and hand off the URL
Why use the Lovable MCP server
- Agent-driven development: Let your client scaffold and iterate on Lovable projects using natural language.
- Code inspection: Read project files, diff changes, and browse edit history programmatically.
- Cross-tool workflows: Combine Lovable with other MCP-connected tools in a single agent session.
Common use cases
Prerequisites
- A Lovable account on any plan.
- Third-party MCP client access enabled for your workspace, which allows external clients to connect to the Lovable MCP server
- Enabled by default on Free, Pro, and Business workspaces
- Disabled by default on Enterprise workspaces. On Enterprise, a workspace admin or owner can enable it in Settings → Security → Privacy & security, under Third-party MCP clients
- One of the supported AI clients installed
Before you connect
How to connect
The Lovable MCP server uses OAuth for authentication. When you connect for the first time, your client opens a browser window to authenticate with your Lovable account.ChatGPT
ChatGPT
Claude
Claude
Open the connector picker
Browse connectors
Connect and authenticate
Claude Code
Claude Code
/mcp (look for the lovable server) or ask Claude Code to “list my Lovable workspaces.”Claude Desktop (config file)
Claude Desktop (config file)
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
mcpServers object with other servers in it, add the "lovable" entry inside the existing object. Don’t paste a second mcpServers block, the file won’t be valid JSON.Cursor
Cursor
/lovable-new, /lovable-iterate, /lovable-db, and /lovable-deploy. Sign in with your Lovable account when prompted on the first tool call.To connect the server manually instead, add the following to your MCP configuration (~/.cursor/mcp.json globally, or .cursor/mcp.json in your project root):mcp.json already has an mcpServers object with other servers in it, add the "lovable" entry inside the existing object. Don’t paste a second mcpServers block, the file won’t be valid JSON.VS Code
VS Code
Available tools
The Lovable MCP server exposes the following tools. Tool calls run with your Lovable account’s permissions and operate on your real projects.Identity and workspaces
Projects
Agent interaction
Knowledge and skills
Code inspection
Cloud database
Connectors
Analytics
File uploads
Client-specific tools
Two tools only appear in certain clients:render_project_widgetshows a live build-progress widget aftercreate_project. It appears in clients that support MCP Apps, such as ChatGPT.import-claude-design-from-urlimports a Claude design into a new Lovable project. It appears in Claude clients only.
Skills
A skill is a reusable instruction file that tells your AI client how to use the Lovable MCP server effectively: when to trigger it, how to sequence tool calls, and what patterns to follow. Add it to your client once and it will know how to drive Lovable without extra prompting. Lovable publishes the skill at mcp.lovable.dev/skill.md. It is maintained alongside the server, so it always matches the tools the server currently exposes. Download the file and add it to your client’s skills or instructions directory, for example.claude/skills/lovable-mcp/SKILL.md for Claude Code.
Troubleshooting
Tools not showing after connecting
Tools not showing after connecting
tools/list to confirm the connection. If tools don’t appear, troubleshoot based on how you connected:- Connected through the client’s UI (OAuth): Open your client’s connector or MCP settings, remove the Lovable entry, and add it again to re-run the OAuth flow.
- Using a config file: Open the config file and confirm the JSON is valid and the
"lovable"entry is nested inside the existingmcpServersobject. Restart the client after saving.
Workspace not found
Workspace not found
list_workspaces to retrieve valid workspace IDs. If you omit workspace_id on create_project, Lovable picks the workspace automatically when only one is eligible; if multiple workspaces qualify, the tool returns a WAITING response listing them so you can re-call with a specific workspace_id.Project not found
Project not found
list_projects with the workspace ID to find the correct ID.No database found
No database found
enable_database first (takes 30-60 seconds), then retry.SQL query returns no results
SQL query returns no results
SELECT table_name FROM information_schema.tables through query_database first, then query the table you need.MCP client prompts you to sign in again (SSO workspaces)
MCP client prompts you to sign in again (SSO workspaces)
401 Unauthorized and a WWW-Authenticate: Bearer error="invalid_token" challenge. Spec-compliant MCP clients (Claude Desktop, Cursor, Claude Code) automatically restart the OAuth flow, which opens a browser window so you can re-authenticate against your identity provider.To resolve it, complete the sign-in prompt in your browser. Your client picks up the new token automatically and tool calls resume.See Set up single sign-on (SSO) for how workspace owners and admins configure session duration.FAQ
What is the difference between the Lovable MCP server and chat connectors?
What is the difference between the Lovable MCP server and chat connectors?
Which plans can use the Lovable MCP server?
Which plans can use the Lovable MCP server?
Can I connect with an API key?
Can I connect with an API key?
Does using the MCP server consume my Lovable credits?
Does using the MCP server consume my Lovable credits?
create_project and send_message calls. Other tools are free.What permissions does the MCP server have?
What permissions does the MCP server have?