# Managing redirects

**URL:** <https://forums.concretecms.org/t/managing-redirects/7671>\
**Category:** Using Concrete / Help\
**Created:** [June 23, 2024, 9:14pm UTC](https://forums.concretecms.org/t/managing-redirects/7671 "2024-06-23T21:14:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![deanhawthorn](https://forums.concretecms.org/user_avatar/forums.concretecms.org/deanhawthorn/32/4118_2.png) [@deanhawthorn](https://forums.concretecms.org/u/deanhawthorn)\
**Post date:** [June 23, 2024, 9:14pm UTC](https://forums.concretecms.org/t/managing-redirects/7671/1 "2024-06-23T21:14:26Z")

</div>

Ive updated an old site safely, by cloning it the a temporary sub-domain, then applying updates, in case it broke it. This has been successful and its now on version 9+.  
Both old and new sites are on the same server, original on database 01, and new site (sub-domain) using database 02.  
I have tried copying new site files over to public\_html folder and removing all canonical redirects and cache files, but when I navigate to the original domain (not sub domain) it keeps redirecting to the sub-domain site.  
If I try and force redirects using file in application/config/generated\_overrides/concrete.php I just end up in a redirections loop which times out after 20 goes.

Am I missing something obvious please?

---

<div class="post-metadata">

**Author:** ![hutman](https://forums.concretecms.org/user_avatar/forums.concretecms.org/hutman/32/6198_2.png) [@hutman](https://forums.concretecms.org/u/hutman)\
**Post date:** [June 24, 2024, 5:46pm UTC](https://forums.concretecms.org/t/managing-redirects/7671/2 "2024-06-24T17:46:16Z")

</div>

Do you have any references to your subdomain in the application/config/generated\_overrides files?

Does your .htaccess file have any references to the subdomain?

Have you deleted all the files in application/files/cache after the copy?

---

<div class="post-metadata">

**Author:** ![mhawke](https://forums.concretecms.org/user_avatar/forums.concretecms.org/mhawke/32/6297_2.png) [@mhawke](https://forums.concretecms.org/u/mhawke)\
**Post date:** [June 24, 2024, 9:32pm UTC](https://forums.concretecms.org/t/managing-redirects/7671/3 "2024-06-24T21:32:59Z")

</div>

Further to hutman’s suggestions, as a habit, I always put a blank .htaccess file in the new site and let the system build it when I enable ‘pretty urls’ and other stuff from the dashboard.

---

<div class="post-metadata">

**Author:** ![deanhawthorn](https://forums.concretecms.org/user_avatar/forums.concretecms.org/deanhawthorn/32/4118_2.png) [@deanhawthorn](https://forums.concretecms.org/u/deanhawthorn)\
**Post date:** [June 26, 2024, 7:16pm UTC](https://forums.concretecms.org/t/managing-redirects/7671/4 "2024-06-26T19:16:36Z")

</div>

It was solved by my hosting support.  
They suggested the problem was in the site.php file.  
I added the correct domain in:  
‘canonical\_url’  
‘canonical\_url\_alternative’

I also checked the correct domain was in concrete.php

I think my error was trying to edit the urls using the back end of C5 then moving the files. Instead I moved the files then manually edited the ones above and it worked. I also deleted all the cache files.
