What you’ll need
- A list of your old URLs (from a sitemap, analytics or Search Console)
- DirectAdmin access
Changing URLs without redirects loses search rankings and breaks bookmarks and links from other sites. A redirect map keeps them working.
Steps
Step 1: Collect old URLs
Export URLs from your old sitemap, analytics landing pages and Google Search Console’s pages report. Prioritise pages with traffic or external links.
Step 2: Map each to its best match
In a spreadsheet, list each old URL beside its closest new equivalent. Avoid sending everything to the home page.
Step 3: Write the rules
Turn each row into a line at the top of
public_html/.htaccess:Redirect 301 /services.html https://yourdomain.co.uk/what-we-do/ Redirect 301 /contact-us.php https://yourdomain.co.uk/contact/For whole sections, use
RedirectMatch. Redirects with .htaccess: copy-ready examplesStep 4: Test a sample
Visit several old URLs in a private window and confirm each lands on the right page in one hop.
Step 5: Check for 404s
Over the next few weeks, check the access log and Search Console for old URLs still returning 404, and add rules for them. 404 Not Found: why pages are missing and how to fix it
Check it worked
Every old URL on your list returns a single 301 to its mapped page, confirmed with a redirect checker.
If something goes wrong
| What happens | What to do |
|---|---|
| Redirect loops | A rule’s target matches its own pattern. “Too many redirects” and HTTPS redirect loops |
| 500 error after saving | .htaccess syntax. What is .htaccess? A practical guide |
Traxio accounts include SSH, Git, cron and PHP 7.4 to 8.3. Try the PHP hosting is free for 30 days with no card, then £0.99 a month.