Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Helpful shortcuts for VSCode

VSCode Shortcuts

List of helpful shortcuts for faster coding

If you have any other helpful shortcuts, feel free to add in the comments of this gist :)

Official List of all commands

Open/View

Open Command Pallete

Shift+Cmd+P
Shift+Ctrl+P

Access Settings

Cmd+,
Ctrl+,

Toggle Terminal

Ctrl+`
Ctrl+`

Create New Terminal

Shift+Ctrl+`
Shift+Ctrl+`

Toggle Sidebar

Cmd+B 
Ctrl+B

Open New Window/Instance

Shift+Cmd+N 
Shift+Ctrl+N

Close Window

Cmd+W 
Ctrl+W

Working With Files

Sidebar Focus

Shift+Cmd+E
Shift+Ctrl+E

Open File/Folder From Sidebar

Cmd+Down
Ctrl+Down

Change File Tabs

Ctrl+Tab 
Ctrl+PageUP

Quick File Open

Cmd+P
Ctrl+P

Open File From Explorer

Cmd+O
Ctrl+O

New File

Cmd+N
Ctrl+N

Save

Cmd+S
Ctrl+S

Save As

Shift+Cmd+S
Shift+Ctrl+S

Close File

Cmd+W
Ctrl+W

Delete File

Cmd+Delete
Ctrl+Delete

Reopen Files

Shift+Cmd+T
Shift+Ctrl+T

Zoom

Cmd++ # Zoom in
Cmd+- # Zoom out

Ctrl++ # Zoom in
Ctrl+- # Zoom out

Spilt Editor

Cmd+\
Ctrl+\

Code Editing

Go To Start & End Of Line

Cmd+Right
Cmd+Left

Ctrl+Right
Ctrl+Left

home
end

Move By Word

Option+Right
Option+Left

Alt+Right
Alt+Left

Go To Start & End Of File

Cmd+Up
Cmd+Down

Ctrl+Home
Ctrl+End

Cut, Copy & Past Line

Cmd+X #Cut
Cmd+C #Copy
Cmd+V #Paste

Ctrl+X # Cut
Ctrl+C # Copy
Ctrl+V # Paste

Move Line Up & Down

Option+Up
Option+Down

Alt+Up
Alt+Down

Copy Line Up & Down

Shift+Option+Up
Shift+Option+Down

Shift+Alt+Up
Shift+Alt+Down

Remove Line

ShiftCmd+K
Shift+Ctrl+K

Insert Line

Cmd+Enter # Insert below
Shift+Cmd+Enter # Insert above

Ctrl+Enter # Insert below
Shift+Ctrl+Enter # Insert above

Jump To Matching Bracket

Shift+Cmd+\
Shift+Ctrl+\

Add Line Comment

Cmd+/
Ctrl+/

Add Block Comment

Shift+Option+A
Shift+Alt+A

Highlight Code

Shift+Any Direction

Select Next Match

Cmd+D
Ctrl+D

De-select Match

Cmd+U
Ctrl+U

Add Cursor

Option+Click
Alt+Click

Go to Entity (Functions, vars, etc)

Cmd+Shift+O
Ctrl+Shift+O
@Fortune-Labs
Copy link

Fortune-Labs commented Oct 3, 2020

wow, very helpful

@ibby360
Copy link

ibby360 commented Oct 7, 2020

Thanks, dawg

@amans199
Copy link

amans199 commented Oct 9, 2020

Very helpful, thanks

@Elijah-trillionz
Copy link

Elijah-trillionz commented Oct 24, 2020

Very helpful. Thank you

@ericphilbaz
Copy link

ericphilbaz commented Nov 17, 2020

Move By Word

Option+Right
Option+Left
Alt+Right
Alt+Left

these shortcut wrong! just ctrl+...

@kekkoong1004
Copy link

kekkoong1004 commented Nov 19, 2020

Thank you

@turecarlson
Copy link

turecarlson commented Dec 9, 2020

Thanks for putting this together!

@parthokr
Copy link

parthokr commented Jan 25, 2021

Cool! Thank you.

@priyanshm07
Copy link

priyanshm07 commented Mar 3, 2021

Grateful to you sir.
Using these shortcuts really helped a lot.

@yasirroni
Copy link

yasirroni commented Mar 12, 2021

Add changing between group, source: stackoverflow

Ctrl+1, Ctrl+2, Ctrl+3
Cmd+1, Cmd+2, Cmd+3

Copy link

ghost commented Apr 27, 2021

Thank you

@Suyash-Purwar
Copy link

Suyash-Purwar commented Apr 27, 2021

Thank you so much!

@cbreland
Copy link

cbreland commented Apr 29, 2021

shift + control + right
Highlight everything between brackets. Use multiple times to keep expanding outward.

shift + control + left
To minimize inward.

@iDestin
Copy link

iDestin commented May 11, 2021

Thank you

@IMArjunreddy
Copy link

IMArjunreddy commented May 26, 2021

thanks a lot :-)

@bharathrajappa
Copy link

bharathrajappa commented Jul 30, 2021

Thanks

@PierreDZ
Copy link

PierreDZ commented Aug 18, 2021

Thank you very much !

@narzk
Copy link

narzk commented Sep 25, 2021

helpful thank you

@teemotimy
Copy link

teemotimy commented Oct 5, 2021

Thank you so much for this, Sire.

@jhynes94
Copy link

jhynes94 commented Jan 5, 2022

Really nice collection. Thanks Brad!

@dapao8525389
Copy link

dapao8525389 commented Jan 13, 2022

Is there an undo commend in Mac?

@sadoyin
Copy link

sadoyin commented Jan 30, 2022

Very helpful

@Trapz107
Copy link

Trapz107 commented Feb 12, 2022

Thank you very much, these helps me so much while coding and increases my productivity

@mobo-9-0045
Copy link

mobo-9-0045 commented Feb 23, 2022

Im looking How to navigate from 2 opened files in same winows of vscode

@faisalamin001
Copy link

faisalamin001 commented Mar 21, 2022

Thanks, so useful shortcuts

@vyjith
Copy link

vyjith commented Mar 25, 2022

Thanks very usefull shortcuts 🤝

@flex91
Copy link

flex91 commented Mar 30, 2022

very helpful thank you

@ProKelly
Copy link

ProKelly commented Jun 10, 2022

this is awesome thanks

@LoannExe
Copy link

LoannExe commented Jul 6, 2022

and to zoom and dezoom?

@LUNA56144
Copy link

LUNA56144 commented Jul 11, 2022

Thank you. Very helpful

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment