Cycling Through Editor Tabs In VSCode
Nov 1 · 1 min read

I was less than thrilled with VSCode’s default keyboard shortcuts for cycling through open editor tabs. Here’s an easy to way to update them such that they’re in line with the more universally adopted approach used by Chrome, finder, iTerm, and more, i.e. CMD + 1 opens the first tab, CMD + 2 opens the second tab, etc.
CMD + SHIFT + P .
Type Open Keyboard Shortcuts (JSON) .
Press ENTER.
Paste the following block between the opening and closing square brackets:
{"key": "cmd+0","command": "workbench.action.lastEditorInGroup"},{"key": "cmd+1","command": "workbench.action.openEditorAtIndex1"},{"key": "cmd+2","command": "workbench.action.openEditorAtIndex2"},{"key": "cmd+3","command": "workbench.action.openEditorAtIndex3"},{"key": "cmd+4","command": "workbench.action.openEditorAtIndex4"},{"key": "cmd+5","command": "workbench.action.openEditorAtIndex5"},{"key": "cmd+6","command": "workbench.action.openEditorAtIndex6"},{"key": "cmd+7","command": "workbench.action.openEditorAtIndex7"},{"key": "cmd+8","command": "workbench.action.openEditorAtIndex8"},{"key": "cmd+9","command": "workbench.action.openEditorAtIndex9"},{"key": "ctrl+1","command": "workbench.action.focusFirstEditorGroup"},{"key": "ctrl+2","command": "workbench.action.focusSecondEditorGroup"},{"key": "ctrl+3","command": "workbench.action.focusThirdEditorGroup"},
Press CMD + S to save.
Enjoy!

