PHPackages                             fsylum/rector-wordpress - 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. fsylum/rector-wordpress

ActiveRector-extension[Utility &amp; Helpers](/categories/utility)

fsylum/rector-wordpress
=======================

Rector upgrades rules for WordPress

1.0.0(5mo ago)2218.4k↑303.1%4MITPHPPHP &gt;=8.2CI passing

Since Jan 21Pushed 5mo ago2 watchersCompare

[ Source](https://github.com/fsylum/rector-wordpress)[ Packagist](https://packagist.org/packages/fsylum/rector-wordpress)[ RSS](/packages/fsylum-rector-wordpress/feed)WikiDiscussions main Synced yesterday

READMEChangelog (7)Dependencies (9)Versions (9)Used By (0)

Rector Rules for WordPress
==========================

[](#rector-rules-for-wordpress)

This package is a [Rector](https://github.com/rectorphp/rector) extension developed to provide upgrade rules for WordPress.

Requirements
------------

[](#requirements)

- PHP 8.2 or higher
- Rector 2.0 or higher

Install
-------

[](#install)

Install the `rector-wordpress` package as dependency:

```
composer require fsylum/rector-wordpress --dev
```

Use Sets
--------

[](#use-sets)

To add a set to your config, use `Fsylum\RectorWordPress\Set\WordPressSetList` class and pick one of the constants. For example, to update the codebase to WordPress 6.8, use `WordPressSetList::WP_6_8`.

```
use Fsylum\RectorWordPress\Set\WordPressSetList;
use Rector\Config\RectorConfig;

return static function (RectorConfig $rectorConfig): void {
    $rectorConfig->sets([
        WordPressSetList::WP_6_8,
    ]);
};
```

You can also use a level set list to include all the applicable rules from the lowest version, 0.71 up to the one you specified. For example, `WordPressLevelSetList::UP_TO_WP_6_8` will include all the rules from WordPress 0.71 up to 6.8. In most cases, this is the preferable way to transform your code as you only need to specify it once.

```
use Fsylum\RectorWordPress\Set\WordPressLevelSetList;
use Rector\Config\RectorConfig;

return static function (RectorConfig $rectorConfig): void {
    $rectorConfig->sets([
        WordPressLevelSetList::UP_TO_WP_6_8,
    ]);
};
```

Supported WordPress Versions
----------------------------

[](#supported-wordpress-versions)

This package provides upgrade rules for WordPress versions from 0.71 to 6.8, covering:

- WordPress 0.71, 1.0, 1.2, 1.5
- WordPress 2.x (2.0 through 2.9)
- WordPress 3.x (3.0 through 3.9)
- WordPress 4.x (4.0 through 4.9)
- WordPress 5.x (5.0 through 5.9)
- WordPress 6.x (6.0 through 6.8)

###  Health Score

48

—

FairBetter than 93% of packages

Maintenance69

Regular maintenance activity

Popularity38

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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 ~119 days

Recently: every ~177 days

Total

7

Last Release

179d ago

Major Versions

0.5.0 → 1.0.02026-01-05

### Community

Maintainers

![](https://www.gravatar.com/avatar/1f008ec20e3ae65d0f6e8c0f127921710e0f2ec2620eb9c8ad598ecb8d164658?d=identicon)[fsylum](/maintainers/fsylum)

---

Top Contributors

[![fsylum](https://avatars.githubusercontent.com/u/3433880?v=4)](https://github.com/fsylum "fsylum (32 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StyleLaravel Pint

Type Coverage Yes

### Embed Badge

![Health badge](/badges/fsylum-rector-wordpress/health.svg)

```
[![Health](https://phpackages.com/badges/fsylum-rector-wordpress/health.svg)](https://phpackages.com/packages/fsylum-rector-wordpress)
```

###  Alternatives

[driftingly/rector-laravel

Rector upgrades rules for Laravel Framework

1.2k15.4M729](/packages/driftingly-rector-laravel)[ssch/typo3-rector

Instant fixes for your TYPO3 PHP code by using Rector.

2603.2M435](/packages/ssch-typo3-rector)[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k15](/packages/tempest-framework)[phpactor/phpactor

PHP refactoring and intellisense tool for text editors

1.9k17.1k1](/packages/phpactor-phpactor)[sylius/promotion

Flexible promotion management for PHP applications.

28505.6k15](/packages/sylius-promotion)[sylius/money-bundle

Currencies and money formatting engine bundle for Symfony.

19681.3k26](/packages/sylius-money-bundle)

PHPackages © 2026

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