PHPackages                             mrchetan/php\_standard - 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. [PSR &amp; Standards](/categories/psr-standards)
4. /
5. mrchetan/php\_standard

ActivePhpcodesniffer-standard[PSR &amp; Standards](/categories/psr-standards)

mrchetan/php\_standard
======================

PHP coding standard to be followed in Laravel projects

5.3.0(7mo ago)612131MIT

Since Jul 17Pushed 4mo ago2 watchersCompare

[ Source](https://github.com/mrchetan/PHPStandard)[ Packagist](https://packagist.org/packages/mrchetan/php_standard)[ GitHub Sponsors](https://github.com/mr-chetan)[ RSS](/packages/mrchetan-php-standard/feed)WikiDiscussions main Synced today

READMEChangelog (10)Dependencies (1)Versions (47)Used By (1)

PHP Coding Standard
===================

[](#php-coding-standard)

This repository contains rulesets for **PHP CodeSniffer** and **PHP Mess Detector** along with some custom rules.

Installation
------------

[](#installation)

Install this repository globally using following composer commands:

```
composer global require mrchetan/php_standard
```

Always use the latest version of the repository.

Setup
-----

[](#setup)

The project will be installed in global composer folder on your PC.

- **Mac**: `.composer/vendor` folder in your home directory
- **Windows**: `AppData/Roaming/Composer/vendor` folder in your user directory
- **Ubuntu**: `.config/composer/vendor` folder in your home directory

You follow the steps respective to your favourite IDE to configure PHP CodeSniffer and PHP MessDetector and point to the two rulesets in the installation folder.

- **ruleset.xml** - For CodeSniffer

Attribution
-----------

[](#attribution)

Some sniffs in this repository have been derived from original PHP\_CodeSniffer project. Credits for those go to the respective developers.

VS Code SETUP
-------------

[](#vs-code-setup)

Install the extension name **[Sniffer of PHP](https://marketplace.visualstudio.com/items?itemName=MrChetan.sniffer-of-php)** by **MrChetan**

[![Sniffer of PHP](./img/sniffer-of-php.png)](https://marketplace.visualstudio.com/items?itemName=MrChetan.sniffer-of-php)After Activation add the below file to settings.json file

For Mac

```
"phpSniffer.standard": "~/.composer/vendor/mrchetan/php_standard/ruleset.xml",

```

For Linux

```
"phpSniffer.standard": "~/.config/composer/vendor/mrchetan/php_standard/ruleset.xml",

```

For Windows

```
"phpSniffer.standard": "%userprofile%/AppData/Roaming/Composer/vendor/mrchetan/php_standard/ruleset.xml",

```

To check

```
phpcs --standard=

```

For Example

```
phpcs --standard=~/.composer/vendor/mrchetan/php_standard/ruleset.xml index.php

```

TO fix

```
phpcbf --standard=

```

Ignoring a file

```
// @codingStandardsIgnoreFile

// phpcs:ignoreFile

```

Ignoring a line

```
// @codingStandardsIgnoreLine

// phpcs:ignore

```

Ignoring a block

```
// @codingStandardsIgnoreStart

// phpcs:disable

// @codingStandardsIgnoreEnd

// phpcs:enable

```

###  Health Score

44

—

FairBetter than 90% of packages

Maintenance70

Regular maintenance activity

Popularity16

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 97.6% 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 ~35 days

Recently: every ~70 days

Total

46

Last Release

217d ago

Major Versions

1.3 → 2.0.02022-02-12

2.3.6 → 3.0.02023-06-12

3.2.7 → 4.0.02023-07-19

4.3.0 → 5.0.02025-02-25

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/79189789?v=4)[Chetan](/maintainers/mrchetan)[@mrchetan](https://github.com/mrchetan)

---

Top Contributors

[![mr-chetan](https://avatars.githubusercontent.com/u/56998650?v=4)](https://github.com/mr-chetan "mr-chetan (80 commits)")[![amitchandrakar](https://avatars.githubusercontent.com/u/22864828?v=4)](https://github.com/amitchandrakar "amitchandrakar (1 commits)")[![rodrigoprimo](https://avatars.githubusercontent.com/u/77215?v=4)](https://github.com/rodrigoprimo "rodrigoprimo (1 commits)")

---

Tags

phpphpcslaravelCoding Standardphp-code-snifferphpcs-standardmrchetandevanoxphpcs-rulesetphpcs-standard-laravel

### Embed Badge

![Health badge](/badges/mrchetan-php-standard/health.svg)

```
[![Health](https://phpackages.com/badges/mrchetan-php-standard/health.svg)](https://phpackages.com/packages/mrchetan-php-standard)
```

###  Alternatives

[orisai/coding-standard

Strict PHP coding standard

20199.0k68](/packages/orisai-coding-standard)[yoast/yoastcs

PHP\_CodeSniffer rules for Yoast projects

221.2M34](/packages/yoast-yoastcs)

PHPackages © 2026

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