LESS to SASS Converter
Convert LESS stylesheets to SASS indented syntax online. Transform @variables to $variables, remove braces and semicolons, and preserve nesting — free and instant.
LESS Input
SASS Output
Example
Here's a real-world LESS snippet converted to SASS indented syntax. Paste your own LESS code above to try it instantly.
Card Component — LESS to SASS
LESS input:
Converted SASS output:
Click Sample to load this example into the editor, or paste your own LESS code directly.
What Is LESS to SASS Conversion?
LESS and SASS are both CSS preprocessors that add variables, nesting, and reusable logic on top of plain CSS. They solve the same problems but with different syntax. LESS uses @variable: value; and curly-brace blocks just like CSS. SASS's original indented syntax skips the braces and semicolons entirely — indentation defines structure instead.
Converting LESS to SASS means renaming @variables to $variables, stripping curly braces and semicolons, and letting indentation carry the meaning. The result is often more readable for developers who prefer a clean, whitespace-driven style. If you're migrating a project from LESS to a Sass-based build pipeline, this tool handles the tedious mechanical parts instantly.
How to Use
Paste or upload your LESS code
Type or paste your LESS stylesheet into the left editor, or click Upload to load a .less file from your machine.
Conversion happens automatically
As you type, the tool converts in real time. @variables become $variables, braces and semicolons are stripped, and indentation is adjusted to match SASS's whitespace-based structure.
Copy or download the SASS output
Use Copy to put the SASS on your clipboard, or Download to save a .sass file. Drop it straight into your Sass project.
When Does This Tool Help?
You're most likely to need this when migrating an older project that was built with LESS to a modern Sass-based stack. Many CSS frameworks and build tools have moved to SCSS or SASS as their primary preprocessor, and keeping LESS in your pipeline just adds an extra dependency. Running your files through this converter is a good first pass before manual cleanup.
It's also handy when you're copying a code snippet from a LESS-based project into your Sass codebase. Manually renaming every @var to $var and stripping braces is tedious — paste it here and it's done in a second. For a deeper look at the differences between the two preprocessors, CSS-Tricks has a solid comparison.
Frequently Asked Questions
What is the difference between LESS and SASS?
Both are CSS preprocessors, but they use different syntax. LESS uses @variable: value; and standard CSS braces. SASS (the original indented syntax) uses $variable: value with no braces or semicolons — whitespace defines nesting instead. SCSS is a newer variant of Sass that looks more like CSS.
What does this converter actually change?
It renames @variable declarations to $variable, replaces @variable usages in values, removes curly braces and semicolons from property lines, and re-indents the output to match SASS's whitespace-based structure. At-rules like @media and @keyframes are left untouched.
Does this handle LESS mixins and functions?
Basic nesting and variables are fully handled. LESS mixins, .mixin() calls, and built-in LESS functions (like lighten()) will appear in the output but may need manual adjustment since SASS handles mixins differently using @mixin and @include.
Is this different from converting LESS to SCSS?
Yes. SCSS keeps curly braces and semicolons, so it looks closer to CSS. SASS indented syntax strips them out entirely. Both are valid Sass dialects. Use LESS to SCSS if you want a more CSS-like output, or use this tool if you prefer clean indented SASS.
Can I use the output directly in a Sass project?
In most cases, yes — but review the output before using it in production. LESS-specific features like parametric mixins, loops, and operations may need to be rewritten as Sass equivalents. The tool handles the mechanical syntax conversion; the logic is yours to verify.
Related Tools
Need to go the other direction? Try SASS to LESS, or use LESS to CSS to compile your LESS all the way down to plain CSS.