Python refactorings now available in VS Code with Sourcery!
Get instant Python refactorings as a VS Code extension
Written by Nick Thapen on
We’re excited to announce that Sourcery is now available as a VS Code extension.
This means you can use all of the great features of Sourcery directly in your VS Code editor:
-
Instant Python refactoring suggestions. We’re the only tool that will refactor your code for you! As you type Sourcery will analyse your code and suggest improvements which you can add with one click.
-
We don’t break your code. Sourcery uses extensive static analysis to ensure that its refactorings don’t change the existing functionality - backed up by testing on open source repositories.
-
Runs locally. Sourcery runs completely locally on your machine - no code is ever sent to the cloud.
Here’s an example of a Sourcery refactoring from inside VS Code:

To get it for free just follow these steps:
- Open VS Code and press
Ctrl+P(Cmd+Pon Mac) then paste inext install sourcery.sourceryand pressEnter. - Click here to get a free token.
- Enter the token into the provided input, or search for
sourceryin the VS Code settings and enter it into theSourcery Tokenfield.