PHPackages                             leafo/scssphp - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. leafo/scssphp

Abandoned → [scssphp/scssphp](/?search=scssphp%2Fscssphp)Library[Utility &amp; Helpers](/categories/utility)

leafo/scssphp
=============

scssphp is a compiler for SCSS written in PHP.

v0.8.4(6y ago)1.3k9.9M—3%212[5 issues](https://github.com/leafo/scssphp/issues)[3 PRs](https://github.com/leafo/scssphp/pulls)20MITPHPPHP ^5.4.0 || ^7

Since Jul 30Pushed 6y ago65 watchersCompare

[ Source](https://github.com/leafo/scssphp)[ Packagist](https://packagist.org/packages/leafo/scssphp)[ Docs](http://leafo.github.io/scssphp/)[ RSS](/packages/leafo-scssphp/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (4)Versions (57)Used By (20)

This repo has been archived
===========================

[](#this-repo-has-been-archived)

#### Please go to

[](#please-go-to-httpsgithubcomscssphpscssphp)

---

scssphp
-------

[](#scssphp)

[![License](https://camo.githubusercontent.com/42d9e4e32a6c2ac9352652e6681386cde432de02dc6a15b08f480e58729c01b9/68747470733a2f2f706f7365722e707567782e6f72672f6c6561666f2f736373737068702f6c6963656e73652e737667)](https://camo.githubusercontent.com/42d9e4e32a6c2ac9352652e6681386cde432de02dc6a15b08f480e58729c01b9/68747470733a2f2f706f7365722e707567782e6f72672f6c6561666f2f736373737068702f6c6963656e73652e737667)

`scssphp` is a compiler for SCSS written in PHP.

### Running Tests

[](#running-tests)

`scssphp` uses [PHPUnit](https://github.com/sebastianbergmann/phpunit) for testing.

Run the following command from the root directory to run every test:

```
vendor/bin/phpunit tests

```

There are several tests in the `tests/` directory:

- `ApiTest.php` contains various unit tests that test the PHP interface.
- `ExceptionTest.php` contains unit tests that test for exceptions thrown by the parser and compiler.
- `FailingTest.php` contains tests reported in Github issues that demonstrate compatibility bugs.
- `InputTest.php` compiles every `.scss` file in the `tests/inputs` directory then compares to the respective `.css` file in the `tests/outputs` directory.
- `ScssTest.php` extracts (ruby) `scss` tests from the `tests/scss_test.rb` file.
- `ServerTest.php` contains functional tests for the `Server` class.

When changing any of the tests in `tests/inputs`, the tests will most likely fail because the output has changed. Once you verify that the output is correct you can run the following command to rebuild all the tests:

```
BUILD=1 vendor/bin/phpunit tests

```

This will compile all the tests, and save results into `tests/outputs`.

To enable the `scss` compatibility tests:

```
TEST_SCSS_COMPAT=1 vendor/bin/phpunit tests

```

### Coding Standard

[](#coding-standard)

`scssphp` source conforms to [PSR2](http://www.php-fig.org/psr/psr-2/).

Run the following command from the root directory to check the code for "sniffs".

```
vendor/bin/phpcs --standard=PSR2 bin src tests

```

###  Health Score

52

—

FairBetter than 96% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity69

Solid adoption and visibility

Community53

Growing community involvement

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 58.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~45 days

Recently: every ~11 days

Total

56

Last Release

2526d ago

PHP version history (5 changes)v0.0.5PHP &gt;=5.2.0

v0.1.0PHP &gt;=5.3.0

v0.5.0PHP &gt;=5.4.0

v0.8.3PHP ^5.6.0 || ^7

v0.8.4PHP ^5.4.0 || ^7

### Community

Maintainers

![](https://www.gravatar.com/avatar/d655b33532ef3fa191568c665b7e390e910e1b6f461e06920ea8578820a74ea7?d=identicon)[leafo](/maintainers/leafo)

---

Top Contributors

[![robocoder](https://avatars.githubusercontent.com/u/922051?v=4)](https://github.com/robocoder "robocoder (645 commits)")[![leafo](https://avatars.githubusercontent.com/u/15198?v=4)](https://github.com/leafo "leafo (219 commits)")[![Cerdic](https://avatars.githubusercontent.com/u/342805?v=4)](https://github.com/Cerdic "Cerdic (133 commits)")[![oyejorge](https://avatars.githubusercontent.com/u/1043524?v=4)](https://github.com/oyejorge "oyejorge (20 commits)")[![clue](https://avatars.githubusercontent.com/u/776829?v=4)](https://github.com/clue "clue (15 commits)")[![hason](https://avatars.githubusercontent.com/u/288535?v=4)](https://github.com/hason "hason (14 commits)")[![dleffler](https://avatars.githubusercontent.com/u/83437?v=4)](https://github.com/dleffler "dleffler (6 commits)")[![vladimmi](https://avatars.githubusercontent.com/u/891830?v=4)](https://github.com/vladimmi "vladimmi (4 commits)")[![okj579](https://avatars.githubusercontent.com/u/40447?v=4)](https://github.com/okj579 "okj579 (3 commits)")[![gwillings](https://avatars.githubusercontent.com/u/4246446?v=4)](https://github.com/gwillings "gwillings (3 commits)")[![brainfoolong](https://avatars.githubusercontent.com/u/1684236?v=4)](https://github.com/brainfoolong "brainfoolong (3 commits)")[![caiosm1005](https://avatars.githubusercontent.com/u/4460538?v=4)](https://github.com/caiosm1005 "caiosm1005 (3 commits)")[![nextend](https://avatars.githubusercontent.com/u/4518540?v=4)](https://github.com/nextend "nextend (3 commits)")[![aaukt](https://avatars.githubusercontent.com/u/5297402?v=4)](https://github.com/aaukt "aaukt (2 commits)")[![cyberalien](https://avatars.githubusercontent.com/u/822287?v=4)](https://github.com/cyberalien "cyberalien (2 commits)")[![edwinveldhuizen](https://avatars.githubusercontent.com/u/1787915?v=4)](https://github.com/edwinveldhuizen "edwinveldhuizen (2 commits)")[![guilhermeblanco](https://avatars.githubusercontent.com/u/208883?v=4)](https://github.com/guilhermeblanco "guilhermeblanco (2 commits)")[![IceReaper](https://avatars.githubusercontent.com/u/1322277?v=4)](https://github.com/IceReaper "IceReaper (2 commits)")[![jamesshannon](https://avatars.githubusercontent.com/u/761381?v=4)](https://github.com/jamesshannon "jamesshannon (2 commits)")[![lucvn](https://avatars.githubusercontent.com/u/206688?v=4)](https://github.com/lucvn "lucvn (2 commits)")

---

Tags

csssassscsslessstylesheet

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/leafo-scssphp/health.svg)

```
[![Health](https://phpackages.com/badges/leafo-scssphp/health.svg)](https://phpackages.com/packages/leafo-scssphp)
```

###  Alternatives

[scssphp/scssphp

scssphp is a compiler for SCSS written in PHP.

62827.7M220](/packages/scssphp-scssphp)[wikimedia/less.php

PHP port of the LESS processor

12327.4M77](/packages/wikimedia-lessphp)[efficiently/larasset

Larasset is a library for Laravel 5 which manage assets in an easy way.

684.8k](/packages/efficiently-larasset)[panique/laravel-sass

Compiles your Sass .scss files to .css every time you run your app (in development)

73171.8k1](/packages/panique-laravel-sass)[nizsheanez/yii2-asset-converter

Less, Sass, Scss and Phamlp converter for Yii2. No system requires. yii2-composer support, Less autoupdate, customizing of output directory

64167.5k6](/packages/nizsheanez-yii2-asset-converter)[trentrichardson/cakephp-shrink

Compiles, combines, and minifies javascript, coffee, less, scss, and css

1619.3k](/packages/trentrichardson-cakephp-shrink)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
