MATLAB MCP Server is an official MathWorks integration utility that connects AI applications and coding assistants with MATLAB through the Model Context Protocol. It enables compatible agents to execute MATLAB expressions, run scripts, and retrieve computational results. Integrated static analysis identifies potential programming errors, deprecated functions, and performance issues without executing source files. Automated testing tools execute MATLAB unit tests and return detailed results. Toolbox detection provides information about installed MATLAB components and versions. Configurable session management supports launching new MATLAB instances or connecting to existing sessions. Custom tool definitions extend server functionality. Supported integrations include Claude Code, Codex, and Visual Studio Code.
Features
- Model Context Protocol integration connecting compatible AI coding assistants with local MATLAB environments
- Direct MATLAB code evaluation and execution of supported source scripts and P-code files
- Non-destructive static code analysis with programming diagnostics, performance warnings, and coding standard recommendations
- Automated MATLAB unit test execution with detailed test results and installed toolbox detection
- Configurable MATLAB session management with existing session connectivity and desktop or headless execution modes
- Extensible custom MCP tool definitions with configurable logging, working directories, and telemetry settings