PHPackages                             alt-design/alt-redirect - 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. alt-design/alt-redirect

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

alt-design/alt-redirect
=======================

Alt Redirect addon, add Redirects to your site

v1.8.1(1mo ago)1247.1k↓60.2%12[4 issues](https://github.com/alt-design/Alt-Redirect-Addon/issues)[4 PRs](https://github.com/alt-design/Alt-Redirect-Addon/pulls)MITPHPPHP ^8.1CI failing

Since Nov 3Pushed 1mo ago2 watchersCompare

[ Source](https://github.com/alt-design/Alt-Redirect-Addon)[ Packagist](https://packagist.org/packages/alt-design/alt-redirect)[ RSS](/packages/alt-design-alt-redirect/feed)WikiDiscussions main Synced yesterday

READMEChangelog (10)Dependencies (6)Versions (45)Used By (0)Security (1)

Alt Redirect
============

[](#alt-redirect)

> Ez pz redirects, simple, spicy and nicey.

Features
--------

[](#features)

- Redirects to and from
- Set the status of redirects
- Supports headers on redirects
- Regex Redirects
- Imports and Exports
- URI Query String Stripping

How to Install
--------------

[](#how-to-install)

You can search for this addon in the `Tools > Addons` section of the Statamic control panel and click **install**, or run the following command from your project root:

```
composer require alt-design/alt-redirect
```

Basic usage
-----------

[](#basic-usage)

### Simple redirects

[](#simple-redirects)

Just take a request to one URL and redirect to a new url, for example

From :

```
/old-page

```

To :

```
/new-page

```

### Regex redirects

[](#regex-redirects)

These, other hand, allow much richer redirect functionality.
Lets say you changed a wildcard URL path to be a query parameter on a new page, this can done like so

From :

```
/old-page/(.*)

```

To :

```
/new-page?wildcard=$1

```

the '$x' (where x is a number) elements are arranged in the order the corresponding '(.\*)' appeared in the 'From' URL, this allows rearranging the regexed fields in the 'To' URL.

### Headers on redirect

[](#headers-on-redirect)

You can add headers to the redirect response using the addon's config file. To get started, publish the config file to your site:

```
php artisan vendor:publish --tag=alt-redirect-config
```

In the `headers` property, you can provide an array of headers to be passed to the `redirect` method.

### Query String Stripping

[](#query-string-stripping)

This is a new feature we've added to remove query strings from URIs before they're processed by the redirect middleware.

Because redirects are URI-based, an unexpected query string on a link would've cause your redirects to not function.

With this feature, you can strip out troublesome query strings before your redirects are processed.

Following this, you can choose to either add the query string back to the redirect URL, or strip it out entirely. The default behaviour for this is to add the filtered query strings back after the redirect has been found.

You can set a query string to be stripped using the "strip" toggle in the Query Strings admin panel.

The Query Strings functionality can be found in the nav as a child underneath the Alt Redirect Addon

```
- Alt Redirect
    - Query Strings  'database',
```

#### 4. Migrate Existing Data (Optional)

[](#4-migrate-existing-data-optional)

If you already have file-based redirects and want to move them to your database, you can use the following Artisan command:

```
php artisan alt-redirect:migrate-file-redirects
```

The command will check if the required tables exist and then migrate all your redirects and query strings.

#### Artisan Command

[](#artisan-command)

We have provided an Artisan command to force the creation of defaults.

This will "force" create them, so they'll be installed even if the defaults have already been installed.

This is great for if you've deleted the defaults but want them back or if composer didn't install them during the addon install for some reason.

Simple run the command below and confirm when it asks you too :

```
php artisan alt-redirect:default-query-strings
```

Questions etc
-------------

[](#questions-etc)

Drop us a big shout-out if you have any questions, comments, or concerns. We're always looking to improve our addons, so if you have any feature requests, we'd love to hear them.

Also - check out our other Statamic bits!

### Starter Kits

[](#starter-kits)

- [Alt Starter Kit](https://statamic.com/starter-kits/alt-design/alt-starter-kit)

### Addons

[](#addons)

- [Alt SEO Addon](https://github.com/alt-design/Alt-SEO-Addon)
- [Alt Sitemap Addon](https://github.com/alt-design/Alt-Sitemap-Addon)
- [Alt Akismet Addon](https://github.com/alt-design/Alt-Akismet-Addon)
- [Alt Password Protect Addon](https://github.com/alt-design/Alt-Password-Protect-Addon)
- [Alt Cookies Addon](https://github.com/alt-design/Alt-Cookies-Addon)
- [Alt Inbound Addon](https://github.com/alt-design/Alt-Inbound-Addon)
- [Alt Google 2FA Addon](https://github.com/alt-design/Alt-Google-2fa-Addon)

Postcardware
------------

[](#postcardware)

Send us a postcard from your hometown if you like this addon. We love getting mail from other cool peeps!

Alt Design
St Helens House
Derby
DE1 3EE
UK

###  Health Score

55

—

FairBetter than 97% of packages

Maintenance83

Actively maintained with recent releases

Popularity40

Moderate usage in the ecosystem

Community20

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 55.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 ~25 days

Recently: every ~105 days

Total

38

Last Release

52d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/5221940?v=4)[Alt Design](/maintainers/alt-design)[@alt-design](https://github.com/alt-design)

---

Top Contributors

[![benmAltDesign](https://avatars.githubusercontent.com/u/149595159?v=4)](https://github.com/benmAltDesign "benmAltDesign (72 commits)")[![Alt-Ben](https://avatars.githubusercontent.com/u/12431318?v=4)](https://github.com/Alt-Ben "Alt-Ben (41 commits)")[![Alt-Charlie](https://avatars.githubusercontent.com/u/260397567?v=4)](https://github.com/Alt-Charlie "Alt-Charlie (8 commits)")[![martyf](https://avatars.githubusercontent.com/u/1491079?v=4)](https://github.com/martyf "martyf (3 commits)")[![nat-alt](https://avatars.githubusercontent.com/u/100426312?v=4)](https://github.com/nat-alt "nat-alt (1 commits)")[![stephencockerill](https://avatars.githubusercontent.com/u/14827659?v=4)](https://github.com/stephencockerill "stephencockerill (1 commits)")[![ceesvanegmond](https://avatars.githubusercontent.com/u/883497?v=4)](https://github.com/ceesvanegmond "ceesvanegmond (1 commits)")[![JonKaric](https://avatars.githubusercontent.com/u/8028521?v=4)](https://github.com/JonKaric "JonKaric (1 commits)")[![kevinmeijer97](https://avatars.githubusercontent.com/u/9716909?v=4)](https://github.com/kevinmeijer97 "kevinmeijer97 (1 commits)")

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/alt-design-alt-redirect/health.svg)

```
[![Health](https://phpackages.com/badges/alt-design-alt-redirect/health.svg)](https://phpackages.com/packages/alt-design-alt-redirect)
```

###  Alternatives

[statamic/seo-pro

68516.6k](/packages/statamic-seo-pro)[statamic-rad-pack/runway

Eloquently manage your database models in Statamic.

135224.7k7](/packages/statamic-rad-pack-runway)[rias/statamic-redirect

29335.6k](/packages/rias-statamic-redirect)[jacksleight/statamic-bard-texstyle

18195.4k](/packages/jacksleight-statamic-bard-texstyle)[marcorieser/statamic-livewire

A Laravel Livewire integration for Statamic.

23111.5k14](/packages/marcorieser-statamic-livewire)[withcandour/aardvark-seo

Save time and get your Statamic site to rank better with the SEO addon for Statamic.

15133.0k](/packages/withcandour-aardvark-seo)

PHPackages © 2026

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