---
updatedAt: 2025-09-11T20:04:57.000Z
agentTools:
  projectIndex: https://docs.makaira.io/llms.txt
---

# Redirects

Redirects allows us to direct certain URLs to a targeted URL.

## Types of redirects that can be created

* Permanent (301, 308)
* Temporary (302, 303, 307)

## Application examples

* Redirects can be used for search engine optimization.
* Redirects can be used to direct users from old pages to the new ones.
* Website relaunch can incorporate redirects in order to direct users to the new website.

***

## Configuration

* Source: relative URL to be redirected (1)
* Code: Type of redirect (2)
* Priority: If more than one redirect rule could match a given source URL then the redirects with the highest priority is used
* Target: relative URL to be redirected to (4)

  <Image align="center" className="border" border={true} src="https://files.readme.io/7288efb-redirect.png" />

## Wildcards

You can use wildcards in order to create rules that can group or match multiple source URLs.

Example:

`/old/* -> /new/`

In this case, all URLs starting with `/old/` will be redirected to `/new/`.

***

Additionally, you can also use the matched values in the source URL to build the target URL.

For instance, the rule:

`/old/*/foo/* -> /new/$1/bar/$2`

would result in the following redirect behaviour:

`/old/my-fancy-product/foo/details -> /new/my-fancy-product/bar/details`

You can use the placeholders in the target URL in arbitrary order. Thus, the above redirect rule could be changed to:

`/old/*/foo/* -> /new/$2/bar/$1`

which would result in the following redirect behaviour:

`/old/my-fancy-product/foo/details -> /new/details/bar/my-fancy-product`

## Bulk-Operations

You can create redirects as bulk with an csv-file, more explanation can be found here: <https://docs.makaira.io/reference/post-bulk-redirect>

You can also download a list of all current redirect rules by clicking on the "Download .csv" button

***