Daytona MCP Server
Daytona Model Context Protocol (MCP) server enables AI agents to interact with Daytona Sandboxes programmatically. This guide covers how to set up and use the MCP server with various AI agents.
Install Daytona CLI
Section titled “Install Daytona CLI”Install the Daytona CLI to manage the MCP server.
brew install daytonaio/cli/daytonapowershell -Command "irm https://get.daytona.io/windows | iex"Authenticate with Daytona
Section titled “Authenticate with Daytona”Authenticate with Daytona to enable MCP server access.
daytona loginInitialize MCP server
Section titled “Initialize MCP server”Daytona provides methods to initialize the MCP server with your preferred AI agent. Supported agents include Claude, Cursor, and Windsurf.
# Initialize with Claudedaytona mcp init claude
# Initialize with Cursordaytona mcp init cursor
# Initialize with Windsurfdaytona mcp init windsurfAfter initialization, open your AI agent application to begin using Daytona features.
Configure MCP server
Section titled “Configure MCP server”Daytona provides methods to generate MCP configuration for integration with other AI agents.
daytona mcp configThis command outputs a JSON configuration that you can copy into your agent’s settings:
{ "mcpServers": { "daytona-mcp": { "command": "daytona", "args": ["mcp", "start"], "env": { "HOME": "${HOME}", "PATH": "${HOME}:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/homebrew/bin" }, "logFile": "${HOME}/Library/Logs/daytona/daytona-mcp-server.log" } }}Start MCP server
Section titled “Start MCP server”Daytona provides methods to manually start the MCP server.
daytona mcp startAvailable tools
Section titled “Available tools”Daytona MCP server provides the following tools for interacting with Daytona Sandboxes:
- Sandbox management
- File system operations
- Git operations
- Process and code execution
- Computer use
- Preview
Troubleshooting
Section titled “Troubleshooting”To troubleshoot issues with the Daytona MCP server, try the following:
- Authentication issues: run
daytona loginto refresh credentials - Connection errors: verify MCP server configuration, check server status
- Sandbox errors: use
daytona listto check sandbox status
If the issue persists, contact support@daytona.io.