How-to · VS Code for Mac

How to open settings.json in VS Code on Mac: three routes for macOS, 2026

To open settings.json in VS Code on Mac, press ⇧⌘P, type Preferences: Open User Settings (JSON), and press Return. You can also choose File > Preferences > Settings or press ⌘, to start from the Settings editor.

Updated Checked against VS Code desktop app on macOS, checked against stable release 1.1452 minEasy

Person typing on a MacBook, learning how to open settings json in VS Code on Mac
Editing a settings file takes a few careful keystrokes. · Image by StockSnap from Pixabay

Quick answer

  • Press ⇧⌘P, type Preferences: Open User Settings (JSON), then press Return.
  • Or choose File > Preferences > Settings, or press ⌘, to open the Settings editor.
  • User settings live at ~/Library/Application Support/Code/User/settings.json.
  • Project settings live in .vscode/settings.json and override your user settings for that project.
  • If you see Unable to write settings, look for a missing comma or a stray character.

What you need

  • VS Code installed on a Mac, Apple silicon or Intel
  • A stable release. These steps were checked against release 1.145
  • For project settings, the project folder open in VS Code

How to Open settings.json in VS Code on Mac in VS Code on a Mac

  1. Open the Command Palette

    ⇧⌘P

    Click inside the VS Code window so it is active. Press ⇧⌘P, which means Shift, Command, and P together. A search box appears near the top of the window.

    Tip: If nothing appears, click inside the editor first and try again.

  2. Type the settings command

    Type Preferences: Open User Settings (JSON). The list narrows as you type. Choose the entry that ends in (JSON).

    Tip: Read the full entry before you press Return, since similar names sit close together.

  3. Open settings.json

    Return

    Press Return. VS Code opens settings.json in a new editor tab. Each setting appears as a key and a value, with quotes and commas.

    Tip: The tab name should read settings.json. If you see another file name, close it and run the command again.

  4. Use the File menu instead

    FilePreferencesSettings⌘,

    Click File in the menu bar at the top of the screen. Choose Preferences, then Settings. The Settings editor opens with User and Workspace tabs.

    Tip: This route opens the visual editor first. Use step 5 to reach the file from there.

  5. Jump to the file from a setting

    In the Settings editor, look for an Edit in settings.json link under some settings. Click it to open the file. Not every setting shows this link.

    Tip: If the link is missing, go back to step 1. That route opens the file directly.

  6. Make ⌘, open the JSON file

    ⌘,

    Press ⌘, to open the Settings editor. Search for workbench.settings.editor in the search box. Set its value to json. Press ⌘, again to check.

    Tip: Write down the old value first, so you can switch back later.

  7. Open the project workspace file

    ⇧⌘P

    Open the project folder in VS Code. Run Preferences: Open Workspace Settings (JSON) from the Command Palette. The file is .vscode/settings.json in the project root.

    Tip: Use this file for rules that apply only to this project.

  8. Save and check your change

    ⌘S

    Press ⌘S to save. Then test the setting and see whether it behaves the way you expected. If it does not, press ⌘Z to undo.

    Tip: If the file shows an error, fix it before you test the setting.

Open settings.json from the Command Palette

The Command Palette is the fastest route. It runs VS Code commands by name, and you find one by typing part of its name. Start by clicking inside the VS Code window so it is active.

Press ⇧⌘P. A search box appears at the top of the window. Type Preferences: Open User Settings (JSON), then choose the matching entry.

Check the suffix before you press Return. The entry that ends in (JSON) opens the file itself, which is what you want here. Pressing Return runs the highlighted command. If that entry does not show, scan the list for the one that ends in (JSON).

Person typing on a MacBook, learning how to open settings json in VS Code on Mac
Editing a settings file takes a few careful keystrokes. · Image by StockSnap from Pixabay

Open settings.json from the File menu

If you prefer menus, click File in the menu bar at the top of the screen. Choose Preferences > Settings, or press ⌘, (Command and comma). The Settings editor opens with two tabs, User and Workspace.

The Settings editor is not the JSON file. It shows settings as forms with a search box, so you can change most things without typing any JSON. Pick the User tab for your personal settings.

Some settings show an Edit in settings.json link. That link does not appear on every setting. When you do not see it, go back to the Command Palette route, which opens the file directly.

Why edit the JSON instead of the Settings editor?

The Settings editor covers most common settings with a search box. The JSON file helps when you want to copy a setting to another Mac, or when you need a key the editor does not show. Both routes change the same settings, so you can switch between them.

Pick the route that matches the job. Use the editor to browse and search. Use the file when you already know the key name and want to type it directly.

Worked example: turn on word wrap in your user file

Open the user file with ⇧⌘P and Preferences: Open User Settings (JSON). Find the last line that holds a setting, which sits just above the closing brace. Add a comma at the end of that line if it has none.

On a new line, type "editor.wordWrap": "on". Do not add a comma after it, because it is now the last entry. Then press ⌘S to save the file, and check whether long lines wrap in your editor.

If a red mark appears on the line above, you most likely forgot the comma. Fix that first, then check the result again. This small edit uses the same pattern as most changes you will make by hand.

Make ⌘, open the JSON file every time

If you edit the JSON file often, you may want ⌘, to skip the visual editor. Set the workbench.settings.editor setting to json. After that, File > Preferences > Settings and ⌘, open settings.json directly.

The change takes only a few moves. Press ⌘, to open the Settings editor. Search for workbench.settings.editor in the search box at the top. Set its value to json.

This changes what ⌘, does for every project, so write down the old value first. You can set it back at any time if you want the visual Settings editor again.

Where the file lives on a Mac

The user settings file sits in your home folder. Its full path is $HOME/Library/Application Support/Code/User/settings.json. To reach it by hand, choose Go > Go to Folder in Finder and paste the path that starts with ~/Library.

Where each settings file lives and how to open it
FileWhere it livesHow to open it
User settings (default profile)~/Library/Application Support/Code/User/settings.json⇧⌘P, then Preferences: Open User Settings (JSON)
Workspace settingsThe .vscode/settings.json file in the project root⇧⌘P, then Preferences: Open Workspace Settings (JSON)
Non-default profile~/Library/Application Support/Code/User/profiles/<profile ID>/settings.jsonExists only after you change a setting in that profile

Profile files only appear after you change a setting in that profile. Until then, the folder may not contain the file at all. That is expected, not a sign that something broke. To open the default profile's file, run Preferences: Open Application Settings (JSON).

Programmer at a laptop reviewing code, the kind of editor window where settings json lives
A code editor window, where most settings changes happen. · Image by Alexandra_Koch from Pixabay

User and workspace settings: which one wins

VS Code reads settings in layers. The order runs Default, then User, then Workspace, then Workspace Folder. Policy settings always win when they are set.

Later layers override earlier ones. Simple values and arrays get replaced completely. Object values get merged, so keys from both files can survive.

Use the workspace file for rules that belong to one project. Keep personal taste, such as font and theme, in the user file. That keeps each shared project clean.

Edit settings.json without breaking it

Settings files use JSON. Each entry holds a key in double quotes, a colon, and a value. Entries are separated by commas, and the last entry has no comma after it.

A line looks like this: `"editor.wordWrap": "on"`. The key sits on the left and the value on the right. Copy the pattern exactly, including the quote marks.

VS Code highlights malformed JSON in the editor. Watch for red marks and read the message next to them. Save only after the marks clear.

Change one setting at a time. Save, then check the result. If something breaks, press ⌘Z to undo the last edit before you try another fix.

Fix the Unable to write settings error

VS Code shows Unable to write settings when the file has a problem it cannot save past. The official settings docs say malformed JSON can cause this. A missing comma is one cause the docs name directly.

Scroll to the spot where the red mark sits. Look at the line just above it. Two entries side by side need a comma between them. Add it, then press ⌘S to save.

If the commas look right, look for stray characters. An extra brace, a curly quote, or an unclosed quote mark will break the file too. Delete the character, then save again.

Developer desk with a Mac, notebook, and coffee while setting up VS Code
A clean desk makes editor setup easier to follow. · Image by yeiferr from Pixabay

Mistakes people make when they open settings.json

One mistake is editing the workspace file when you meant the user file. Check the tab title and the file path before you type. Workspace files sit in .vscode/settings.json in the project root.

Another mistake is adding a key you never changed and expecting it to show. The file usually holds only the settings you changed. You can type any valid key yourself.

The third mistake is a setting that seems ignored. A workspace value or a policy can override the user value you set. Check the workspace file before you blame VS Code.

Using VS Code in a browser

The web version at vscode.dev works differently. Its docs list ⇧⌘P as the Command Palette shortcut, but that shortcut does not launch in Firefox. In Firefox, press F1 instead.

The web docs also say the terminal and the debugger are not available in the browser. They do not say whether settings.json exists there. Do not assume the desktop steps work the same way in a browser.

Settings Sync and your settings file

Settings Sync keeps VS Code preferences consistent across devices. You turn it on or off from the Manage gear menu or the Accounts menu. The official docs list both places.

If you use Settings Sync on more than one Mac, check its state before a big edit. Otherwise a change may appear on one machine and not the other, which is hard to trace.

How many people use VS Code

Plenty of developers use VS Code. In the 2026 Stack Overflow survey, 70.9% of respondents said they use Visual Studio Code, which is 9,350 of 13,193 people.

70.9%

of 2026 Stack Overflow respondents said they use Visual Studio Code (9,350 of 13,193)

Stack Overflow Developer Survey 2026: Dev IDEs

The 2025 survey put that figure at 75.9%, and it drew over 49,000 responses from 177 countries. The sources I checked do not explain the drop, and both figures count all respondents.

Why does this matter for you? Your settings file holds your setup for the editor you use every day. Knowing where it lives makes backups and moves much easier.

Which VS Code version these steps cover

The latest stable release I checked is 1.145, dated November 4, 2026. Its release notes cover file exclusion and managed settings. They do not cover the Settings editor or the Preferences menu.

I could not confirm that these exact steps stayed the same in older releases. The notes for 1.144 and earlier list titles only. If a menu label looks different on your Mac, trust the command name in the Command Palette.

Next steps after you open the file

Once the file is open, you can change settings such as word wrap, auto save, or the color theme. Each has its own guide: turn on word wrap, turn on auto save, and change the color theme.

If you compare settings with code, split the editor to keep both files on screen while you work.

Keep the settings file small. Add keys as you need them, and remove the ones you no longer use. A short file is easier to read when something goes wrong.

VS Code shortcuts for this on Mac

VS Code keyboard shortcuts on Mac
To do thisPress
Open the Command Palette⇧⌘P
Open the Settings editor⌘,
Open Keyboard Shortcuts⌘K⌘S
Save the open file⌘S
Command Palette in Firefox on vscode.devF1

If it does not work

The Command Palette does not open
Click inside the VS Code window first, so it has focus. Then press ⇧⌘P again. Shortcuts follow your current keyboard layout, so check the key labels if the combination does not match. In Firefox on the web version, use F1.
⌘, opens the Settings editor, not the file
That is the default behavior. Set workbench.settings.editor to json as described above. If you want the visual editor back, set it to the value you wrote down.
Unable to write settings appears
Look for red marks in the file. A missing comma between two entries can cause this. Fix the spot the mark points to, then save. The docs say malformed JSON is highlighted in the editor.
The file for my new profile is missing
Profile files appear only after you change a setting in that profile. Change one setting, then look again in the profiles folder. To open the default profile's file, run Preferences: Open Application Settings (JSON).
A setting does not take effect
Check the workspace file, because it overrides user values for that project. Policy settings win over both. Simple values get replaced, so a workspace value can hide your user value completely.

Faster with Lazur

Do it faster: ask Lazur while you are in VS Code

Hold ⌥ ⌘ and say what you want. Lazur sees your VS Code window. Lazur guides you one click at a time and waits for each click.

  • 1

    Hold ⌥⌘ and talk

  • 2

    Lazur guides you one click at a time and waits for each click.

  • 3

    You stay in VS Code. Nothing to copy into a chat window.

Free for 3 days, then $18/month. Download for Mac

You say“Where do I open settings.json in VS Code?”

Lazur · walks you through itLazur points at the File menu, then guides you through Preferences and Settings one click at a time, waiting for each click.

VS Code
ExplorerSearchFile menuClick here firstSource ControlRun

Questions people ask

Where is settings.json on a Mac?

For user settings, the file is at $HOME/Library/Application Support/Code/User/settings.json, inside your home folder. To reach it by hand, choose Go > Go to Folder in Finder and paste the path that starts with ~/Library. Workspace settings sit in .vscode/settings.json inside each project.

What is the shortcut to open settings.json?

The official docs list ⇧⌘P for the Command Palette, then the Preferences command for the JSON file. ⌘, opens the Settings editor. To make ⌘, open the JSON file, set workbench.settings.editor to json.

Why does ⇧⌘P not work for me?

Click inside the VS Code window first, so it has focus. Shortcuts follow your current keyboard layout, so check the key labels if the combination does not match. In Firefox on the web version, press F1 instead, because ⇧⌘P does not launch there.

Can I open settings.json in the browser version?

The official web docs do not say whether settings.json exists in vscode.dev, so this page cannot confirm the steps there. The same docs say the terminal and the debugger are not available in the browser.

What is the difference between user and workspace settings?

User settings apply to your VS Code setup in general. Workspace settings live in .vscode/settings.json and apply to one project. Workspace values override user values for that project, and policy settings win over both.

Why does Unable to write settings appear?

The official settings docs say malformed JSON can cause this error, and a missing comma is one cause they name. Look for red marks in the file, fix the spot they point to, and save again.

Does Settings Sync copy my settings to other Macs?

The Settings Sync docs say it keeps VS Code preferences consistent across devices. You turn it on or off from the Manage gear menu or the Accounts menu, so check that state before you assume a change will follow you.

Should I back up settings.json before I edit it?

Yes, for larger edits. Copy the file to a folder outside VS Code first, so you can restore the old version if a change goes wrong. Keep the copy somewhere you will remember.

Which version do these steps cover?

The steps were checked against the latest stable release I found, 1.145, dated November 4, 2026. No official note says the steps changed, but the notes for 1.144 and earlier list titles only, so older versions are not confirmed.

Sources

  1. User and workspace settings: VS Code Docs · Microsoft · checked 2026-11-09
  2. Settings: VS Code Docs (Getting Started) · Microsoft · checked 2026-11-09
  3. User Interface: VS Code Docs · Microsoft · checked 2026-11-09
  4. Key Bindings for Visual Studio Code · Microsoft · checked 2026-11-09
  5. VS Code Updates: Release Notes · Microsoft · checked 2026-11-09
  6. VS Code for the Web: VS Code Docs · Microsoft · checked 2026-11-09
  7. Settings Sync: VS Code Docs · Microsoft · checked 2026-11-09
  8. Stack Overflow Developer Survey 2026: Dev IDEs · Stack Overflow · checked 2026-11-09
  9. Stack Overflow Developer Survey 2025: Technology · Stack Overflow · checked 2026-11-09
  10. Stack Overflow Developer Survey 2025 · Stack Overflow · checked 2026-11-09

Try Lazur free for 3 days

Hold a key and ask. Lazur sees your screen, points at the button and talks you through it, in any Mac app. No credit card.