The 304 error code means Not Modified, yet it is not really an error. It sits in the 3xx redirection family and is a polite message from the server: the file you asked for has not changed since the copy you already have, so there is no need to send it again.
Your browser keeps copies of images, scripts and pages in its cache. When it wants to show them again, it asks the server whether they are still fresh. If they are, the server replies with a 304 and an empty body, and the browser uses the saved copy. You mostly meet a 304 in developer tools, speed test reports or server logs, and it means things are working properly.
Common causes
1Browser checked its cached copy and it was current
How to tellAppears in developer tools beside images, scripts and style files
What fixes itNothing to fix; this saves data and time
2Normal reload of a page you opened recently
How to tellPage loads quickly the second time
What fixes itNo action needed
3Site shows old content after you updated it
How to tellYour change on the site is not visible even though you saved it
What fixes itHard refresh, or clear the cache and caching layers on the site
4Caching plugin or proxy returns 304 too eagerly
How to tellOwner sees stale pages for visitors after edits
What fixes itOwner purges the cache and checks the validators the server sends
5Monitoring tool counts 304 as a failure
How to tellA checker flags a working page as an error
What fixes itSet the checker to treat 3xx replies as healthy
6Search crawler asking if a page changed
How to tell304 entries in logs from search bots
What fixes itFine; it shows the page is unchanged
How to fix it, step by step
Do nothing if the page looks right
If the page opens and looks correct, the 304 did its job. It is a speed feature, and there is no repair to make.
Hard refresh to fetch a fresh copy
If you expect new content and still see the old one, press Ctrl + Shift + R on Windows, or Cmd + Shift + R on a Mac. On a phone browser, reload from the menu or clear the site's data in the browser settings.
Test in a fresh incognito tab
A private tab starts with an empty cache and asks for everything again. If the new version shows there, your normal browser was holding the old copy.
Clear the site's cached files
In the browser settings, find the option for browsing data or site data, choose cached images and files, and clear them. Signing in again may be needed if you also clear cookies.
Check that your edit was really saved
If you manage a site, confirm that the change is saved and published. Sometimes the page is fine and the edit never went live.
Purge caches on the site side
Owners should clear any caching layers they use, such as a page cache, a server cache or a CDN cache, and then test in a private window.
What the 304 error code means in plain words
Picture asking a friend whether your notes are still the latest version. If nothing has changed, your friend says no change, keep your copy, and you do not need to copy the whole notebook again. The server does the same, using small tags called validators: an ETag or a Last-Modified date. The browser sends the tag it has, and the server compares it with the current one.
In your browser's network view you see a logo image with 304 Not Modified and a tiny size. The logo was not downloaded again; the saved copy was used. That is exactly what you want.
Is a 304 error bad for my website?
No. A healthy site returns many 304 replies, because they cut bandwidth and make pages feel faster, especially on a mobile connection with limited data. Search engines also use them to see if a page needs to be crawled again. A problem only arises when stale content is held for too long, which is a cache setting and not a 304 fault.
If a tool reports 304 as an error, change the tool's settings rather than the website. The response is correct.
304 compared with 200 and 302
| Code | What it says | Body sent |
|---|---|---|
| 200 | Here is the content | Yes |
| 302 | Look at another address for now | Usually no |
| 304 | Your saved copy is still good | No |
Learn more about 200 OK and 302 Found, or go to the full HTTP status codes list.
Tuning cache headers as a site owner
- Send validators such as an ETag so that browsers can ask and receive a quick 304.
- Set sensible cache times: long for images and style files that rarely change, short for pages that change often.
- Rename files when they change so visitors fetch the new version immediately.
- Purge caches after updates so edits are visible without waiting.
Frequently asked questions
What is the 304 error code?
Not Modified is the label HTTP gives to this number. It tells the browser its saved copy is still current, so the server sends no new content.
Does the 304 error code mean something is broken?
No. The 304 error code means caching worked. It is a normal, helpful reply and not a fault.
Why can I not see my website changes, and is the 304 to blame?
The 304 only says the browser used its saved copy. The real cause is a cached version. Hard refresh, use a private window and purge any site caches.
What does error code 304 mean on a phone?
The same thing: your phone browser or app reused a saved file because it had not changed on the server.
Should I try to remove 304 responses?
No. They save data and time. Removing them would only make pages slower and use more mobile data.