<p>I had a Craft Site, which I'll refer to here as the <strong>old site</strong>. I replaced it with a <strong>new site</strong> on the same server. To do this I overwrote the <strong>old site's</strong> database and files. I kept the <strong>old site's</strong> public web root folder intact, and assigned a different web root folder to my <strong>new site</strong> via my hosting control panel.</p>
<p>Long story short, my <strong>new site</strong> launched and everything looks great. Except... when Craft loads my 404 template it shows the one from my <strong>old site</strong>. That template, to the best of my knowledge, doesn't exist on this server anymore (see update below). It's a new database. I have a 404 template for my <strong>new site</strong> that works fine on my local dev machine, but in production it will only show me the <strong>old site's</strong> 404.</p>
<p>Anybody know how I can troubleshoot this? I renamed the <strong>old site's</strong> web root folder (which, again, I'm not even sure is part of the problem) and that didn't change anything. I've cleared my caches. I've tested on multiple devices.</p>
<p>I'm hosted at FortRabbit, if that helps.</p>
<p><strong>UPDATE: I found a copy of the <strong>old site's</strong> 404 template in a file in the <em>compiled_templates</em> folder. I tried renaming that file with no luck (Craft just generates a new one). But it all certainly feels related. Any ideas?</strong></p>

CC BY-SA 4.0
2020-12-02T08:54:46.990Z
Have you tried clearing the template caches? If not, go into the control panel under Utilities > Clear Caches and clear the "Template caches" there.
Alex Roper
CC BY-SA 4.0
2020-12-03T14:01:15.510Z
Yeah, I started there. Also tried the option to 'invalidate template caches' to no avail.
Dannie
<404><error-templates>
How can I best troubleshoot a 404 error loading a template from a previous iteration of my site?
# How can I best troubleshoot a 404 error loading a template from a previous iteration of my site?

(Asked by: username_0 on 2020-12-01)

I had a Craft Site, which I'll refer to here as the **old site**. I replaced it with a **new site** on the same server. To do this I overwrote the **old site's** database and files. I kept the **old site's** public web root folder intact, and assigned a different web root folder to my **new site** via my hosting control panel.

Long story short, my **new site** launched and everything looks great. Except... when Craft loads my 404 template it shows the one from my **old site**. That template, to the best of my knowledge, doesn't exist on this server anymore (see update below). It's a new database. I have a 404 template for my **new site** that works fine on my local dev machine, but in production it will only show me the **old site's** 404.

Anybody know how I can troubleshoot this? I renamed the **old site's** web root folder (which, again, I'm not even sure is part of the problem) and that didn't change anything. I've cleared my caches. I've tested on multiple devices.

I'm hosted at FortRabbit, if that helps.

**UPDATE: I found a copy of the **old site's** 404 template in a file in the *compiled\_templates* folder. I tried renaming that file with no luck (Craft just generates a new one). But it all certainly feels related. Any ideas?**

**Tags:** 404, error-templates
> **Comments:**
> **username_1**: Have you tried clearing the template caches? If not, go into the control panel under Utilities > Clear Caches and clear the "Template caches" there.  
> **username_0**: Yeah, I started there. Also tried the option to 'invalidate template caches' to no avail.  

---

## 0 answers

