VS Code: How To Change Indentation (2 spaces, 4 spaces)
( 40 Articles)
This short and straight-to-the-point article shows you how to change the indentation in VS Code (Visual Studio Code).
1. Open your VS Code and:
- Go to Code > Preferences > Settings if you’re using macOS (shortcut: Command + ,).
- Go to File > Preferences > Settings if you’re using Windows (hotkey: Ctrl + ,).
2. Type “Indentation” into the search field then head to the “Editor: Tab Size” section. Replace the default space number with your preferred one:
Your setting will be applied and reflected immediately. If this doesn’t happen (it’s a little lag sometimes), just reload or restart your VS Code.
- VS Code: 3 Ways to Change Terminal Font SIze
- How to Change File Encoding in VS Code
- VS Code: How to Render Whitespace Characters
- VS Code: How to Disable/Enable Suggestions on Hover
- VS Code: 3 Ways to Change Color of Comments
You can also check out our Visual Studio Code topic page for more tips and tricks to improve your producibility and coding experience. Happy coding!