Setup Visual Studio Code for Unity on Mac 2022

· 3 min read
Setup Visual Studio Code for Unity on Mac 2022

There are tons of articles online tells us it is 2020, we should use the Visual Studio code, which is a good coding tool (or IDE) with numerous extensions. This article is the complete and most easy guide on how to config your Visual Studio Code.

Things I am using:

  • Macbook Pro 2017 and Mac mini M1
  • Unity: 2019.3.15f1 (Any Unity above this will work)
  • Visual Studio Code: 1.46.0  (Any version above this will work)

Step 1: Install the .Net Core SDK, you can download the SDK from here:

The latest version as of today is .NET Core 7.0. Download the pkg/dmg file and install.

Note if you are using a Silicon (M1/M2) Mac, Please choose .NET SDK Arm64

Step 2: Install the mono, someone also suggested to download from its official website from:, I tried but not successful. Here I would show how I installed, copy and paste the following command to your terminal:

brew update && brew install mono

The above command will take a while! After installation, you should be able to see a path in your terminal, this is IMPORTANT, keep the path!:


You probably see a different version here, which doesn't matter. If you can't see the version information, do run the following command will also can help you to get the mono version:

brew install mono
# Warning: mono is already installed and up-to-date.
# To reinstall, run:
#  brew reinstall mono

Step 3: Install necessary extensions:

Some extensions are necessary for project and coding, such as code auto completion, code formatting and so on. I would recommend the following three extensions:

As the day of today (12 Feb 2023), the first extension is make into deprecated. So just the bottom 2 should be OK.

Step 4: many tutorials claimed they already successfully with above three steps. However it doesn't work for me, some essential features are missing, i.e. VS Code even can't auto complete the Rigidbody2D for me. After googled around, I found the following trick:

Go to Code-> Preferences -> Settings, then search mono, and click Edit in settings.json.

Then in the opened setting.json, search and find mnisharp.monoPath and put the path from step 2, and change the value of omnisharp.useGlobalMono to always, one example of my configuration:

    "editor.fontFamily": "'Ubuntu Mono'",
    "editor.fontLigatures": true,
    "editor.fontSize": 14,
    "workbench.colorTheme": "GitHub Light",
    "editor.renderWhitespace": "none",
    "explorer.confirmDelete": false,
    "editor.codeLens": false,
    "git.enableSmartCommit": true,
    "omnisharp.useGlobalMono": "always",
    "omnisharp.monoPath": "/usr/local/Cellar/mono/",

Quit and restart your Visual Studio Code to make the changes effective.