Lists available Convex deployments and returns a deployment selector for use in subsequent calls
Lists all tables in a deployment along with their declared and inferred schemas
Paginates through documents in a specified table
Executes a sandboxed JavaScript query against the deployment's data
Lists all functions in a deployment along with their types and visibility
Executes a specified function in the deployment
Lists all environment variables for a deployment
Gets the value of a specific environment variable
Sets the value of an environment variable
Removes an environment variable from a deployment
Convex's MCP server enables AI agents to interact with your Convex deployments through a standardized interface. It supports introspecting tables and functions, executing queries and mutations, and even writing one-off sandboxed queries to analyze data safely. Since Convex queries are fully sandboxed and can't write to the database without explicit permission, it's safe to let AI agents explore and analyze your data through code. This makes it particularly powerful for ad-hoc data analysis, schema suggestions, and function execution without risking data integrity.
Convex MCP Server allows AI agents to interact with your Convex deployments, providing access to database tables, functions, and environment variables. This integration enables AI assistants to help you analyze data, execute functions, and manage your Convex applications.
mcp.json
While primarily tested with Cursor on macOS, the Convex MCP server should work with other agents like Windsurf and Claude Desktop using the same command. The configuration may vary slightly depending on the agent.
After installation, your AI assistant can:
status
tooltables
and data
toolsrunOneoffQuery
functionSpec
run
toolThe workflow typically starts with the agent calling status
to get a deployment selector, which is then used in subsequent calls to identify which deployment to work with.
The Convex MCP server is particularly useful for:
Since Convex queries are sandboxed, AI agents can safely write and execute code without risking data corruption or unintended side effects.