prettier/plugin-php

Prettier PHP Plugin

Hosted by Prettier

View on GitHub ↗Jump to charts ↓

prettier/plugin-php has 1.5k+ stars and 100+ forks on GitHub, is written in PHP, and was last pushed on Sep 10, 2026. Data as of . Signed-in members get hourly updates — create a free account.

Summary Information

Updated 1 hour ago
Added to GitGenius on October 12th, 2026
Created on December 24th, 2017
Open Issues & Pull Requests: 151 (+0)
GitHub issues: Enabled
Number of forks: 140
Total Stargazers: 1,852 (+0)
Total Subscribers: 23 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 13.2 days
Mean response time: 127.4 days
90th percentile: 571.6 days
Tracked items: 37

How this project is maintained

98% of open issues come from outside the core team, so the backlog reflects real-world use rather than internal planning. Three people close 79% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 41
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 606 days
Stale 30+ days: 41
Stale 90+ days: 39

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

  • bug (7)
  • discussion (2)
  • enhancement (2)
  • inline (1)
  • needs investigation (1)
  • psr compat (1)

Most active issues this week

Sign in to see which issues are moving.
Sign in

Detailed Description

Prettier PHP Plugin is a code formatter that extends Prettier to support PHP files.

The plugin solves the problem of inconsistent PHP code formatting by parsing PHP source code and reprinting it according to Prettier's opinionated style rules. It integrates with Prettier's existing ecosystem, allowing developers to format PHP alongside JavaScript, TypeScript, and other supported languages using a single configuration and command-line interface. The formatter handles PHP syntax parsing and applies consistent indentation, spacing, and line breaking decisions automatically.

Developers should adopt this plugin if they work in polyglot projects where PHP coexists with other languages already formatted by Prettier, or if they prefer Prettier's formatting philosophy for PHP code. It suits teams that want to eliminate formatting discussions by applying an automated, consistent standard across their codebase. The plugin works as a standard Prettier plugin, so it integrates naturally into existing Prettier workflows without requiring separate tooling or configuration paradigms.

The project maintains active engagement with its codebase, regularly addressing reported issues and incorporating community feedback. Development includes ongoing refinement of PHP syntax support and compatibility with new Prettier versions. The maintainers respond to edge cases and formatting inconsistencies raised by users, demonstrating commitment to improving the formatter's reliability across diverse PHP code patterns.