Websites
Site Redirects
Redirects send visitors from an old URL to a new one, which is how you restructure a site without breaking every link pointing at it. This guide covers the three source shapes, choosing between 301 and 302, query strings, and reading the verification badge.
Where Redirects Live in KPanel
- Sign in to KPanel.
- Click Websites in the left sidebar, then click the site.
- In the site's tab strip, open Advanced, then Redirects.
The direct address is /websites/<site-id>/redirects.

Redirects here are applied by the web server, before your application runs. That makes them faster than a plugin-based redirect and means they work even for URLs your application would not recognise at all.
Adding a Redirect
- Click Add redirect.
- Enter the Source path.
- Enter the Destination.
- Choose 301 Permanent or 302 Temporary.
- Decide whether to keep Preserve query string ticked.
- Click Add redirect.
The redirect is applied and then checked against your site directly, so the status you see reflects real behaviour rather than an assumption.
The Three Source Shapes
| Shape | Example | Matches |
|---|---|---|
| Exact | /old-page | That one path only |
| Prefix | /old-path/ | That path and everything beneath it |
| Wildcard | /blog/* | Everything under /blog/, capturing the rest |
A wildcard source captures whatever matched the *, and the destination can reference it as $1. So a source of /blog/* with a destination of /news/$1 sends /blog/hello-world to /news/hello-world, and does the same for every other post, from one rule.
The source path cannot be changed after a redirect is created. If you got it wrong, remove the redirect and add a new one. The destination, the code, and the query setting are all editable.
Destinations
A destination can be either:
- Relative, such as
/new-page, to send visitors elsewhere on the same site. - Absolute, such as
https://example.com/new, to send them to another site entirely.
Absolute destinations are how you build vanity paths: /docs on your domain pointing at documentation hosted elsewhere, for example.
301 or 302
301 Permanent tells browsers and search engines the move is final. Search engines transfer ranking signals to the new URL and stop requesting the old one. Browsers cache the redirect, sometimes for a very long time.
302 Temporary says the move might reverse. Nothing is transferred and nothing is cached long term.
Use 301 for a real restructure: you have moved a page and it is not coming back. Use 302 for anything you expect to undo, such as pointing a page at a temporary campaign or a maintenance notice.
A wrong 301 is expensive to undo. Browsers cache permanent redirects aggressively, so a visitor who hit the bad rule once may keep following it long after you have deleted it, with no way for you to clear their cache. When you are not certain, start with a 302 and promote it to 301 when you are.
Preserve Query String
Preserve query string is on by default. With it on, ?utm_source=newsletter and every other parameter is carried through to the destination.
Leave it on in almost every case. Losing query strings breaks campaign tracking, breaks pagination and filters, and breaks any link that carries state. The redirect list marks any rule with it switched off as (query stripped), so you can see at a glance which ones drop parameters.
Turn it off only when the destination must never receive the old parameters, for example when the old parameters would be interpreted differently and cause the wrong page to render.
Reading the Status Badge
After every save, the redirect is tested against your site directly, not through a cache, and the result becomes the badge in the Status column.
| Badge | Meaning |
|---|---|
| Not yet verified | The check has not run yet. Refresh in a moment |
| Verified, with the code and destination | The redirect is live and doing exactly what you configured |
| Applied but not challenging, with a status | The rule was written but the site returned something else |
The third badge is the one to act on. It means the configuration is in place but the redirect is not taking effect, and the status code shown tells you what happened instead.
You may also see a warning after saving that another configuration on the server claims the same domain. When that happens the redirect will not apply until that conflict is resolved, and the message names the other configuration. Contact support if you see it and are not sure what it means.
Editing and Removing
Each row has an edit button and a remove button.
Editing lets you change the destination, the code, and the query setting. The source is fixed.
Removing asks for confirmation and explains what will happen: requests to that path stop redirecting and return whatever the site normally serves there, which is often a 404.
Planning a Restructure
Before you move a large number of URLs, a little order saves a lot of pain.
- Export your current URL list from your sitemap or your analytics, so you know what actually gets traffic.
- Map old to new, one line per URL. Group anything that shares a prefix.
- Use wildcards for the groups. One
/blog/*rule beats two hundred exact rules and will not drift. - Add exact rules for the exceptions that do not follow the pattern.
- Test each shape once, then check the badges.
- Watch your 4xx count afterwards in Site Traffic Analytics. A rising 404 share means you missed something.
Add a branded 404 page as a safety net for whatever you miss. It turns a dead end into a route back into the site. See Custom Error Pages.
Troubleshooting
The redirect does not fire. Check the badge. If it says applied but not challenging, note the status code returned. A 200 usually means something else answered the request first, often the application itself.
It fires but I land on the wrong URL. Check for a chain: your rule may be sending traffic to a path that another rule, or the application, redirects again. Chains are slow and confuse search engines. Point the first rule directly at the final destination.
A wildcard sends everything to one page. The destination is missing its $1. Without it, every capture collapses onto the same target.
A redirect I deleted still happens in my browser. You previously followed a 301 and your browser cached it. Test in a private window to confirm the rule is really gone.
Query parameters disappear. Preserve query string is switched off on that rule. Edit it and turn it back on.
Too many redirects, or a loop. Two rules are pointing at each other, or a rule points at a path that matches its own source pattern. Remove one side of the loop.
Related Pages
- Custom Error Pages for what visitors see when nothing matches.
- Site Traffic Analytics to watch 3xx and 4xx counts after a restructure.
- Password-Protecting a Site for locking a path rather than moving it.