PHPackages                             humanmade/hm-redirects - 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. humanmade/hm-redirects

ActiveWordpress-plugin[Utility &amp; Helpers](/categories/utility)

humanmade/hm-redirects
======================

Simple plugin for handling WordPress redirects in a scalable manner.

0.7.5(12mo ago)29229.9k↑26.6%10[15 issues](https://github.com/humanmade/hm-redirects/issues)[3 PRs](https://github.com/humanmade/hm-redirects/pulls)2GPL-2.0+PHPPHP &gt;=5.4CI failing

Since May 15Pushed 6mo ago21 watchersCompare

[ Source](https://github.com/humanmade/hm-redirects)[ Packagist](https://packagist.org/packages/humanmade/hm-redirects)[ Docs](https://github.com/humanmade/hm-redirects)[ RSS](/packages/humanmade-hm-redirects/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (3)Versions (25)Used By (2)

HM Redirects
============

[](#hm-redirects)

Allows to redirect one path to another path on the same domain.

Architecture
------------

[](#architecture)

Redirects are stored as a custom post type and use the following fields:

- `post_name` to store the md5 hash of the *From* path. This column is used because it is indexed, and allows fast queries. `md5` is used to simplify the storage.
- `post_title` to store the *From* path.
- `post_excerpt`to store the the *To* path.

Tips
----

[](#tips)

This plugin uses `wp_safe_redirect()` to redirect. You will have to whitelist your redirect target domains using WordPress' `allowed_redirect_hosts` filter, otherwise the redirect will not work. One way to get a list of redirect target domains is to run the WP-CLI command: `wp hm-redirects find-domains`. Another is to add them dynamically just-in-time using the filter `hm_redirects_matched_redirect`.

Attributions
------------

[](#attributions)

Props for the data storage approach to VIP's [WPCOM Legacy Redirector](https://github.com/Automattic/WPCOM-Legacy-Redirector).

Contributing
------------

[](#contributing)

### Before tagging a release

[](#before-tagging-a-release)

- Update the [version string on line 8](hm-redirects.php).

### Running tests

[](#running-tests)

Currently the plugin's automated tests [run against PHP 7.4 and WP 5.8](.github/workflows/phpunit.yml). PHPUnit doesn't need to be installed, however:

```
composer install
docker run --rm -e WP_VERSION=5.8 -v $PWD:/code humanmade/plugin-tester

```

###  Health Score

49

—

FairBetter than 95% of packages

Maintenance50

Moderate activity, may be stable

Popularity46

Moderate usage in the ecosystem

Community33

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~135 days

Recently: every ~290 days

Total

20

Last Release

362d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/21655?v=4)[Ryan McCue](/maintainers/rmccue)[@rmccue](https://github.com/rmccue)

![](https://avatars.githubusercontent.com/u/208434?v=4)[John Blackbourn](/maintainers/johnbillion)[@johnbillion](https://github.com/johnbillion)

![](https://www.gravatar.com/avatar/77dbeefb7745010589603f2ffc6ff310d8f700b58e08d52af190744c43342526?d=identicon)[roborourke](/maintainers/roborourke)

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

![](https://www.gravatar.com/avatar/d17ed8aed4807d5fc1bd0cc6ea2c0dcbd37619882197c42e67da562367cb4631?d=identicon)[fklein-lu](/maintainers/fklein-lu)

---

Top Contributors

[![roborourke](https://avatars.githubusercontent.com/u/23417?v=4)](https://github.com/roborourke "roborourke (40 commits)")[![paulgibbs](https://avatars.githubusercontent.com/u/1275914?v=4)](https://github.com/paulgibbs "paulgibbs (19 commits)")[![mikelittle](https://avatars.githubusercontent.com/u/358499?v=4)](https://github.com/mikelittle "mikelittle (10 commits)")[![fklein-lu](https://avatars.githubusercontent.com/u/1221942?v=4)](https://github.com/fklein-lu "fklein-lu (9 commits)")[![rmccue](https://avatars.githubusercontent.com/u/21655?v=4)](https://github.com/rmccue "rmccue (9 commits)")[![svandragt](https://avatars.githubusercontent.com/u/594871?v=4)](https://github.com/svandragt "svandragt (7 commits)")[![igmoweb](https://avatars.githubusercontent.com/u/1516569?v=4)](https://github.com/igmoweb "igmoweb (6 commits)")[![tcrsavage](https://avatars.githubusercontent.com/u/907521?v=4)](https://github.com/tcrsavage "tcrsavage (4 commits)")[![nanastia](https://avatars.githubusercontent.com/u/79692696?v=4)](https://github.com/nanastia "nanastia (3 commits)")[![mattheu](https://avatars.githubusercontent.com/u/494927?v=4)](https://github.com/mattheu "mattheu (2 commits)")[![joehoyle](https://avatars.githubusercontent.com/u/161683?v=4)](https://github.com/joehoyle "joehoyle (2 commits)")[![spacedmonkey](https://avatars.githubusercontent.com/u/237508?v=4)](https://github.com/spacedmonkey "spacedmonkey (2 commits)")[![johnbillion](https://avatars.githubusercontent.com/u/208434?v=4)](https://github.com/johnbillion "johnbillion (1 commits)")[![robindevitt](https://avatars.githubusercontent.com/u/16571365?v=4)](https://github.com/robindevitt "robindevitt (1 commits)")[![wisyhambolu](https://avatars.githubusercontent.com/u/22037320?v=4)](https://github.com/wisyhambolu "wisyhambolu (1 commits)")[![shantanu2704](https://avatars.githubusercontent.com/u/9296246?v=4)](https://github.com/shantanu2704 "shantanu2704 (1 commits)")

---

Tags

redirectswordpresswordpress-pluginwordpressredirects

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/humanmade-hm-redirects/health.svg)

```
[![Health](https://phpackages.com/badges/humanmade-hm-redirects/health.svg)](https://phpackages.com/packages/humanmade-hm-redirects)
```

###  Alternatives

[roots/bedrock

WordPress boilerplate with Composer, easier configuration, and an improved folder structure

6.5k441.8k2](/packages/roots-bedrock)[cedaro/gravity-forms-iframe

Embed a Gravity Form on any site using an iframe.

1563.0k](/packages/cedaro-gravity-forms-iframe)[iceicetimmy/acf-post-type-selector

Post type selector for Advanced Custom Fields.

559.0k](/packages/iceicetimmy-acf-post-type-selector)

PHPackages © 2026

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