The sections below detail the steps to implement a clean VSCode install, with some useful extensions, settings, and shortcuts.
- Download and install
VSCodefrom https://code.visualstudio.com/download - Download and install
Gitfrom https://git-scm.com/install/ - Download and install
GitHub Desktopfrom https://desktop.github.com/download/ - Download and install
Docker Desktopfrom https://www.docker.com/products/docker-desktop/
Useful VSCode extensions - you can see your installed extensions on the Extensions section of the navigation bar on the left-hand side (you can also open it with Ctrl+Shift+X):
-
Coding
Python(this should also installPylance,Python Debugger, andPython Environments)Jupyter(this should also installJupyter Cell Tags,Jupyter Keymap,Jupyter Notebook Renderers,Jupyter Slide Show)Docker(this should also installContainer Tools)Dev Containers(for developing inside Docker containers directly from VSCode)Black Formatterandisort(extensions for formatting and import organization support for Python files)Data WranglerEven Better TOML(syntax highlighting and validation forpyproject.tomland other TOML files)Rby REditorSupport (language support, syntax highlighting, and IntelliSense for R files)
-
Version control
GitHub Pull RequestsGitLens
-
Aesthetics
Brackets Light ProMarkdown All in OneTheme Switchervscode-iconsvscode-pdf
If using VSCode on Windows, make sure you select Cmd as your default terminal.
- To do this, open the Command Palette in VSCode with
Ctrl+Shift+P. Type in>Terminal: Select Default Profileand chooseCommand Prompt.
VSCode has two levels of settings:
- User settings (
settings.json) apply globally to every project you open. These are the settings modified viaCtrl+Shift+P→>Preferences: Open User Settings (JSON)and are stored in your OS user profile. - Workspace settings (
.vscode/settings.jsonat the project root) apply only to that project and override User settings when the project is open. Because they live inside the project folder, they can be committed to the repository so the whole team shares the same VSCode configuration for that project.
See python_uv.md for an example of a workspace settings.json that configures the Python interpreter path for a specific project.
You can modify your settings in VSCode with Ctrl+Shift+P and typing in >Preferences: Open User Settings (JSON).
The settings.json below worked as of Visual Studio Code 1.112. Settings may evolve across versions - check for deprecated keys if you notice any warnings after upgrading.
{
"editor.wordWrap": "on",
"editor.bracketPairColorization.independentColorPoolPerBracketType": true,
"editor.rulers": [80, {"column": 120, "color": "#ffcc00"}],
"files.autoSave": "onFocusChange",
"gitlens.ai.model": "vscode",
"gitlens.ai.vscode.model": "copilot:gpt-4.1",
"notebook.lineNumbers": "on",
"security.workspace.trust.untrustedFiles": "open",
// "themeswitcher.utcOffset": 1,
// "themeswitcher.mappings": [
// {
// "time": "06:00",
// "theme": "Solarized Dark"
// },
// {
// "time": "07:00",
// "theme": "Brackets Light Pro"
// },
// {
// "time": "18:30",
// "theme": "Solarized Dark"
// }
// ],
"telemetry.telemetryLevel": "off",
"terminal.integrated.defaultProfile.windows": "Command Prompt",
"terminal.integrated.enableMultiLinePasteWarning": "never",
"terminal.integrated.profiles.windows": {
"PowerShell": {
"source": "PowerShell",
"icon": "terminal-powershell"
},
"Command Prompt": {
"path": "C:\\WINDOWS\\System32\\cmd.exe",
"args": []
},
"Git Bash": {
"source": "Git Bash",
"icon": "terminal-git-bash"
}
},
"workbench.iconTheme": "vscode-icons",
"workbench.sideBar.location": "left",
"workbench.colorTheme": "Solarized Dark",
}
Ctrl+Shift+P: open the Command Palette in VSCodeCtrl+P: quick file open (fuzzy search across all files in the workspace)Ctrl+Shift+F: search across all files in the workspaceCtrl+Shift+V: preview a markdown fileCtrl+b: toggle left sidebar on/off (or make selection bold if in a.mdfile)Ctrl+/: toggle line comment on/offCtrl+D: select the next occurrence of the current selection (repeat to select more; useful for multi-cursor editing)Alt+Up/Alt+Down: move the current line (or selected lines) up or downAlt+Click: place an additional cursor at the click position (multi-cursor)F2: rename a symbol across all usages in the file (works with Pylance, the R extension, and other language extensions)Ctrl+K Ctrl+0: fold (collapse) all code sectionsCtrl+K Ctrl+J: unfold (expand) all code sectionsCtrl+': open/close terminal in VSCode
Note
Ctrl+' for the terminal is a custom keybinding - the VSCode default is Ctrl+`. To set or change a keybinding, open the Command Palette with Ctrl+Shift+P and type >Preferences: Open Keyboard Shortcuts. Search for the command you want (e.g. Terminal: Toggle Terminal) and click the pencil icon to assign a new key combination.