You will need two things:

  • tasks.json file
  • Blade Runner extension for VS CODE

Start by creating .vscode folder in your project.

Then in it create tasks.json file with the following content:

{
    "version": "0.1.0",
    "command": "sass",
    "isShellCommand": true,
    "args": ["--watch", "."],
    "showOutput": "always"
}

Now, after opening the project you can run the task by clicking Ctrl+Shift+B.

To automate the process use Blade Runner extension - https://marketplace.visualstudio.com/items?itemName=yukidoi.blade-runner

Blade Runner will run the task automatically after opening the project :)

Answer from gabrieln on Stack Overflow
🌐
Visual Studio Code
code.visualstudio.com › docs › languages › css
CSS, SCSS and Less
November 3, 2021 - Visual Studio Code has built-in support for editing style sheets in CSS .css, SCSS .scss and Less .less. In addition, you can install an extension for greater functionality. Tip: Click on an extension tile above to read the description and reviews to decide which extension is best for you.
🌐
Visual Studio Marketplace
marketplace.visualstudio.com › items
scss-to-css - Visual Studio Marketplace
October 9, 2022 - Extension for Visual Studio Code - 🔥 The easiest way to compile scss file to css. And autoprefixer at the same time.
Top answer
1 of 5
9

You will need two things:

  • tasks.json file
  • Blade Runner extension for VS CODE

Start by creating .vscode folder in your project.

Then in it create tasks.json file with the following content:

{
    "version": "0.1.0",
    "command": "sass",
    "isShellCommand": true,
    "args": ["--watch", "."],
    "showOutput": "always"
}

Now, after opening the project you can run the task by clicking Ctrl+Shift+B.

To automate the process use Blade Runner extension - https://marketplace.visualstudio.com/items?itemName=yukidoi.blade-runner

Blade Runner will run the task automatically after opening the project :)

2 of 5
4

A solution without additional extensions

With sass

Assuming you have sass installed globally with for instance:

npm install -g sass

Open the folder and create a task.json file under .vscode containing

{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
    {
        "label": "Watch Sass",
        "type": "shell",
        "command": "sass --watch src/style.sass styles/style.css --style=compressed",
        "problemMatcher": [],
        "group": {
            "kind": "build",
            "isDefault": true
        },
        "runOptions": {
            "runOn": "folderOpen"
        }
    }]
}

With node-sass

Replace sass with node-sass in the above.

In both cases make sure the source/destination filename, location and extension are correct (in my case src/style.scss and style/style.css)

With a Workspace file

Or copy the section in your .vscode-workspace file to avoid clutter of .json files.

Make sure to change the sass source and destination files to your personal needs.

Setup VSCode

[EDIT] whith the current version this is asked the first time you open the workspace file and the following steps are no longer needed. To a llow automatic run tasks

  1. Ctrl+Shift+P
  2. select Manage automatic Tasks and
  3. select Allow Automatic Tasks in Folder and
  4. close and reopen your folder (or Workspace)

The sass compiler will be called and starts watching all your edits with a reassuring:

Compiled css\src\style.sass to css\style.css.
Sass is watching for changes. Press Ctrl-C to stop.

or with error messages when compilation failed.:

Error: semicolons aren't allowed in the indented syntax.
  ╷
7 │     padding: 0;
  │               ^
  ╵
  css\src\_base.sass 7:12  @import
  css\src\style.sass 1:9   root stylesheet

EDIT command and args can be separated

{
    "label": "Compile sass",
    "type": "shell",
    "command": "sass",
    "args": [
        "--watch",
        "--style=compressed",
        "./style/src/main.sass",
        "./style/main.css"
    ],
    "runOptions": {
        "runOn": "folderOpen"
    }
},
🌐
Medium
medium.com › @codingcarter › how-to-compile-scss-code-in-visual-studio-code-c8406fe54a18
How to Compile SCSS Code in Visual Studio Code | by Coding Carter | Medium
January 24, 2020 - Hello, world and in this tutorial I will be showing you how to compile your SCSS code into CSS using a Visual Studio Code Extension in real time! After you save the .scss file, it will automatically generate the .css file for you! The extension was made by Ritwick Dey, a developer with over 4.3 million downloads on his various extensions on the Visual Studio Marketplace.
🌐
Bangtech
data.bangtech.com › web › how-to-compile-your-sass-to-css-in-visual-studio-code.htm
How To Compile Your SASS/SCSS To CSS In Visual Studio Code
Sass is a CSS preprocessor with enhancements to the CSS syntax. Sass imports and mixings allows us to re-use codes and maintain a larger codebase. ... Close Visual Studio and wait for the installer to appear. Follow the steps to install the extension. Create a file named style.scss in the wwwroot ...
🌐
Visual Studio Marketplace
marketplace.visualstudio.com › items
Live Sass Compiler - Visual Studio Marketplace
Extension for Visual Studio Code - Compile Sass or Scss to CSS at realtime with live browser reload.
🌐
GitHub
github.com › ramya-rao-a › vscode-sasshelper
GitHub - ramya-rao-a/vscode-sasshelper: VSCode extension that helps converting css to scss and to use mixins · GitHub
VSCode extension that helps converting css to scss and to use mixins - ramya-rao-a/vscode-sasshelper
Starred by 11 users
Forked by 4 users
Languages   TypeScript 93.0% | CSS 7.0%
🌐
Coding Campus
codingcampus.net › home › how to compile sass/scss to css in visual studio code
How to Compile SASS/SCSS to CSS in Visual Studio Code - Coding Campus
December 2, 2022 - For example, I am entering the following code: .card { position: relative; background-color: red; .card__name { background-color: blueviolet; } Click on the Watch Sass button from the Status bar at the bottom of VS Code.
Find elsewhere
🌐
MDBootstrap
mdbootstrap.com › standard › material design for bootstrap 5 & vanilla javascript
Compiling SCSS to CSS in Visual Studio Code - Material Design for Bootstrap
That extension is for local scss files if you want to compile large amount of scss you'll need to install sass as devDependencie, npm install -D sass or yarn add -D sass ... Which version of sass do you use? We tried to compile this file on our end and it compiled without errors. Please provide some reproduction steps we need to follow to reproduce the problem. ... Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
🌐
Read the Docs
vscode-docs.readthedocs.io › en › latest › languages › css
CSS, Sass and Less - vscode-docs
This is supported for Sass and Less variables in the same file. Note: Cross file references ('imports') are not resolved. VS Code can integrate with Sass and Less transpilers through our integrated task runner. We can use this to transpile .scss or .less files into .css files.
🌐
YouTube
youtube.com › watch
How to use SCSS in VS Code - YouTube
Live Sass compiler is A VS Code Extension that helps you to compile/transpile your SASS/SCSS files to CSS files at realtime with live browser reloadinstagram...
Published   September 23, 2022
🌐
GitHub
github.com › ritwickdey › vscode-live-sass-compiler
GitHub - ritwickdey/vscode-live-sass-compiler: Compile Sass or Scss file to CSS at realtime with live browser reload feature.
Quick Status bar control. Exclude Specific Folders by settings. Live Reload to browser (Dependency on Live Server extension). ... Open VSCode Editor and Press ctrl+P, type ext install live-sass.
Starred by 658 users
Forked by 173 users
Languages   TypeScript 63.1% | JavaScript 20.9% | HTML 11.3% | SCSS 4.7% | TypeScript 63.1% | JavaScript 20.9% | HTML 11.3% | SCSS 4.7%
🌐
Quora
quora.com › How-do-I-connect-a-SASS-file-to-a-CSS-file-in-VScode
How to connect a SASS file to a CSS file in VScode - Quora
Answer (1 of 2): Do you mean how to convert a Sass file to a CSS file? The best option is to use a build tool like Gulp/Grunt. You can also use module bundlers like Webpack or Parcel but, I think, that would be overkill.
🌐
Visual Studio Marketplace
marketplace.visualstudio.com › items
HTML to CSS / LESS / SCSS - Visual Studio Marketplace
Extension for Visual Studio Code - Copy HTML code and paste it as CSS / LESS / SCSS selectors code
🌐
Medium
medium.com › @coadams9 › css-to-scss-1430c1692556
CSS to Scss!!. When I first started to learn how to… | by Cory Adams | Medium
October 10, 2019 - What follows is some of what I’ve learned over time. One thing I have to mention is the vs code extension “Live Sass Compiler”. This extension takes your Scss and maps it to CSS!
🌐
BlueWindLab
bluewindlab.net › setup-live-sass-compiler-for-visual-studio-code
Setup Live SASS Compiler For Visual Studio Code Editor
June 30, 2025 - Easily install and configure the Live SASS Compiler extension in VS Code. Compile SCSS to CSS in real-time, save, and speed up your front-end development.
🌐
freeCodeCamp
forum.freecodecamp.org › t › vscode-scss-not-compiling-to-css › 484834
VSCode: SCSS not compiling to CSS - The freeCodeCamp Forum
November 9, 2021 - PLEASE if anyone can help I can return it in endless virtual hugs!! I’m working in VSCode using HTML, SCSS and Bootstrap. All installed via npm from the terminal. I was working on and suddenly came across a bug which led to 2 hours of time wasting to find out the SCSS has stopped compiling ...
🌐
GitHub
github.com › microsoft › vscode-css-languageservice
GitHub - microsoft/vscode-css-languageservice: CSS, LESS & SCSS language service extracted from VSCode to be reused, e.g in the Monaco editor.
CSS, LESS & SCSS language service extracted from VSCode to be reused, e.g in the Monaco editor. - microsoft/vscode-css-languageservice
Starred by 374 users
Forked by 201 users
Languages   TypeScript 93.0% | JavaScript 6.6% | TypeScript 93.0% | JavaScript 6.6%
🌐
Testmu
testmu.ai › home › free tools › scss to css converter
SCSS to CSS Converter | TestMu AI
Yes, you can convert SCSS to CSS using various methods such as online converters, command-line tools like Sass, or IDEs like Visual Studio. You can also convert using TestMu AI free online tool.