LESS to SCSS
Translate LESS to SCSS: @variables become $variables, @{…} becomes #{…}. At-rules are left alone.
What LESS to SCSS does
Variables change sign — @brand becomes $brand — and interpolation flips from @{…} to #{…}. The part that needs care is telling a variable from an at-rule: @media, @supports, @import, @font-face, @keyframes and their siblings all start with @ and none of them is a variable, so none is rewritten. Everything else is shared syntax and passes through.
How to use it
LESS to SCSS: paste the LESS into the box above, and press Run to get the SCSS below.
Worked example
Input:
@brand: #0066cc;
@media (min-width: 40rem) {
.card {
color: @brand;
border: 1px solid @brand;
}
}
Output:
$brand: #0066cc;
@media (min-width: 40rem) {
.card {
color: $brand;
border: 1px solid $brand;
}
}
Why it runs in your browser
The conversion happens on this page with JavaScript. Your input is not posted to a server, so it works offline after the page loads and nothing is retained anywhere. The page reads LESS and returns SCSS; reloading the page discards both.
Variables change sign — `@brand` becomes `$brand` — and interpolation flips from `@{…}` to `#{…}`. The part that needs care is telling a variable from an at-rule: `@media`, `@supports`, `@import`, `@font-face`, `@keyframes` and their siblings all start with `@` and none of them is a variable, so none is rewritten. Everything else is shared syntax and passes through.
Translate LESS to SCSS: @variables become $variables, @{…} becomes #{…}. At-rules are left alone.
How to use it
LESS to SCSS: paste the LESS into the box above, and press Run to get the SCSS below.
Why it runs in your browser
The conversion happens on this page with JavaScript. Your input is not posted to a server, so it works offline after the page loads and nothing is retained anywhere. The page reads LESS and returns SCSS; reloading the page discards both.
What to Expect
Best for
- Converting LESS to SCSS when the data is already on screen.
What this tool keeps
- Your input is not posted to a server, so it works offline after the page loads and nothing is retained anywhere.
Sample input
@brand: #0066cc; @media (min-width: 40rem) { .card { color: @brand; border: 1px solid @brand; } }
Sample output
$brand: #0066cc; @media (min-width: 40rem) { .card { color: $brand; border: 1px solid $brand; } }
Frequently asked questions
How do I use the less to scss?
LESS to SCSS: paste the LESS into the box above, and press Run to get the SCSS below.
Is my input uploaded?
No. The text is parsed on this page with JavaScript and is never posted to a server.
Is there a size limit?
Yes: 5 MB per run. Larger input is refused with a message rather than freezing the tab.
Build custom tools for your store
Join the SDK program to create useful ecommerce utilities for your store.