49

I have VS Code 1.15.1 and when I work at two projects at once, I choose File -> New Window and open the second project. Clicking File -> New Window opens new window with VS Code. On my other computer (not sure about the VS Code version there), when I click File -> New Window, instead of opening new window, it will rather open new tab, so that I end up with two tabs in one window, each tab for one project and the active tab occupies whole screen estate.

Any ideas what should I change in Settings to achieve this "single window, multiple tabs" layout when having multiple projects?

I use macos (not sure if OS may be somehow related to the window management settings)

5 Answers 5

133
  1. Go to Preferences > Settings.
  2. Search for native tabs
  3. Check the checkbox
Native tabs checkbox
  1. Code will prompt for restart to take effect.
Dialog box prompt for restart
  1. After restart, make sure you have multiple projects open. And then merge all windows as shown below:
Merge all windows
  1. Enjoy multiple tabs in single window.

Note: I think this applies to all Mac OS >= Sierra. Tested with Catalina, Big Sur, Ventura, Sonoma recently.

Sign up to request clarification or add additional context in comments.

4 Comments

is there a way for this in windows? It's really troublesome to handle four projects like admin ui, admin api ,client ui and client api
In Sonoma I don't have the "Merge All Windows" option :(
Also working on Sequoia.
This is a life changer
39

Just set in your user settings "window.nativeTabs": true and do Window -> Merge All Windows

note: If you have High Sierra installed, that might be an issue.

Here's the link: Better macOS native window tabs support

2 Comments

thank you for response Alex.. though I cannot currently verify if it works, because unfortunately I updated to High Sierra -- and as you properly warned me :) the native tabs don't work there.. just a grey horizontal stripe is displayed where the tabs should be.
In Sonoma I don't have the "Merge All Windows" option :(
15

In Mac OS, there is a system setting outside of VS Code. Set this and then opening files/folders from the command line will also automatically open the file/folder in a new tab instead of a new window.

In MacOS 12.3 (Monterrey) this is under:

  • System Preferences > General > Prefer tabs ____ when opening documents.

Change this setting to always. (The default is in full screen).

You might additionally need to set the setting in VS Code "window.nativeTabs": true as the other commenters have already suggested.

1 Comment

On ventura is shown at System Preferences > Desktop & Dock > Windows & Apps
0

I'm using vscode 1.81.1, and you just need to go to settings -> window. Check the Native Tabs (Applies to all profiles). It will prompt for a restart, do that and you're good to go

1 Comment

what does this add to the existing top answers?
-1

Setting For MAC OS (Ventura V13.1):

Click on code > Settings > settings

Find option: native tabs

Enable and restart VS code

4 Comments

In Sonoma it is not enough
@NisimNaim, Can you please add your configuration in the comment If I missed any?
Aniruddha Mirajkar I have MacOS Sonoma and VS Code Version: 1.86.1. It doesn't work for me. I also don't have the Merge All Windows options that other answers suggested to use.
@NisimNaim , i changed my answer I added the MAC OS version.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.