Run MATLAB in Visual Studio Code

Use the MATLAB® extension for Visual Studio® Code to edit and run MATLAB code in Visual Studio Code (VS Code) with features such as syntax highlighting, code analysis, navigation support, and more.

You can use this extension with or without MATLAB installed on your system. However, to use the advanced features of the extension or run MATLAB code, you must have MATLAB R2021a or later installed.

Get Started with MATLAB Extension for Visual Studio Code

To install the MATLAB extension for Visual Studio Code, see the instructions in the MATLAB extension for Visual Studio Code (GitHub®) repository.

After installing the extension, you might need to configure it to make full use of its features. For more information, see the README file included with the extension. The README file includes a full list of features available with the extension and instructions on how to get started using those features.

For an introduction to the MATLAB extension for Visual Studio Code, you also can see the MATLAB extension for Visual Studio Code (The MATLAB Blog) blog post.

MATLAB function file createSphere.m open in Visual Studio Code with the output of the function displayed in a terminal window below the file

External Websites