Back to Explore
GuideVibeFix editorialUpdated Nov 14, 2026

This Page Is Gone, but the Road Isn't: 404 Pages and Dead-Link Handling for Your Vibe Project

When users open a page that no longer exists, they should not meet a bare line of '404 Not Found'. This guide covers the three pieces of a 404 page, how to write its words, the four causes of dead links, redirects, and the monthly patrol. All example projects, people, and numbers in this guide are fictional.

A real photograph of a screen showing a 404 page: a large '404' and 'Page Not Found', with a dark-blue 'GO HOME' button below.

Three months ago, Xiao Man saved a link to a rare out-of-print magazine on "OldBookstall." Today she remembered it and opened her saved link. The page was blank except for one small line: "404 Not Found." She paused, refreshed once, and saw the same line. She pressed the browser's back button, returned to her saved links, tapped again, and saw the same line. Where had the magazine gone? Was it sold, taken down, or moved somewhere else? The page said nothing at all. She did not know where to look or whom to ask. She closed the page and deleted the saved link too — not because she no longer wanted the magazine, but because the page made her feel the magazine was gone, with no road left to find it by.

Two things first. First, everything in this guide's walkthrough — the project "OldBookstall," the operator "A-Nan," the user "Xiao Man," and all times and quantities — is fictional, invented only to make the flow clear. Second, the boundaries: this site has already published several neighbouring guides — the error and empty states guide is about what the screen says when something goes wrong, a "what to say in the moment" question; the dark mode guide is about switching themes; the maintenance mode guide is about what to show when the whole site is paused, a "the entire site is down" question; the status page guide is about telling all users when a service breaks; the deep linking guide is about how links jump from outside the site to a specific page inside it. This guide repeats none of those. It covers one thing only — what the page should do when a user opens a page that no longer exists. Error messages are about "what to say in the moment," maintenance mode is about "the whole site is down," and the 404 page is about "this one page is gone, but the user is still here." Different jobs.

A real photograph of a screen showing a 404 page: a large '404' and 'Page Not Found', with a dark-blue 'GO HOME' button below.

1. First, the reality: a 404 is not a technical error, it is a user walking into a dead end

When teams hear "404," they treat it as a technical problem: hand it to the backend, fix a few links, done. That is only half right: fixing links means fewer dead ends, but the moment a user hits a dead link, what they feel is not "a technical error" — it is "I walked into a dead end." The user followed a road here — a saved link, a search engine, a link from a friend, a reference in an old article — and halfway down the road it stops, blocked by a wall that reads "404 Not Found." What actually hurts is not "this page is gone" but "I don't know where to go now." The magazine Xiao Man wanted may only have been sold or moved to a new link; one sentence — "This magazine is sold out, here are three similar ones" — would have let her keep browsing. What she got instead was a wall with no door in it.

The fictional example numbers in this guide are: out of 100 visits that hit a 404, 78 people read the words on the page, 61 clicked the on-site search or a recommended link, 44 found the content they wanted, and 29 stayed to keep browsing. These numbers are fictional, and they make one point: the 404 page is a funnel, and every step loses people. Only 78 out of 100 read the words, so the page must first solve "will users even look"; 61 clicked search or a recommendation, so it must also solve "can users find the next road"; in the end only 29 stayed, so it must solve "do users still want to be on this site." Any step done sloppily leaks users at exactly that step.

Here is a second fictional comparison: when a 404 page offers nothing but one line, "404 Not Found," 91 out of 100 people close the page immediately; when the 404 page offers a search box and three recommended links, only 58 out of 100 close it immediately. These numbers are fictional too — the point is not 91 and 58 themselves, but that whether a dead end has a door decides whether users walk or stay. A wall leaves users no choice but to leave; a door gives them a reason to stay. The first rule of 404 pages is this simple: a 404 page is not an error page, it is the page that catches the user — when a user walks into a dead end, your job is not to tell them "you took a wrong turn," it is to point them to a road they can keep walking.

2. The three pieces of a 404 page: say what happened, show the way home, offer a way to keep looking

A 404 page that catches users has exactly three pieces. Miss one, and users leave.

First, say what happened, in plain words: "This page can't be found" — not just "404 Not Found." Users are not engineers; the number 404 means nothing to them. What they need to know is "this page is gone." A good version reads: "This page can't be found — the link may have moved, or the content may have been taken down." One sentence, and users understand: it is not their fault, the page simply is not here. Second, show the way home: a clear "Back to home" button, or a link back to the page they came from. A user who hits a dead end first wants to go back — give them a way home they can see at a glance, instead of making them press the browser's back button and guess where it leads. Third, offer a way to keep looking: an on-site search box, or three to five recommended links. Users came here to find something; this page is gone, but what they want may still be elsewhere on the site — the search box lets them look for it themselves, and the recommendations look for them. Do not offer more than 5 recommendations; beyond 5, users spend so long choosing that they leave while choosing.

The order matters too: say what happened first, then show the way home, then offer a way to keep looking. Users first need to know "what happened," then think "where do I go back to," and only then "what else can I find." Reverse the order and users see five recommended links before anything else and think "where even am I" — and close the page without reading. The worst version has none of the three pieces, only one line of an English error code. That is not a 404 page. That is a wall.

3. How to write the words: do not say "error," do not blame the user, do not pretend nothing happened

404 copy has one rule: use plain words, never jargon, and never blame the user.

First, do not write "Error 404." The word "error" makes users feel they did something wrong — Xiao Man only tapped a link she saved three months ago; she did nothing wrong. Write "This page can't be found," not "The page you requested does not exist" — the words "you requested" amount to saying "you took a wrong turn." Second, do not write correct nonsense. "Please check that the web address you entered is correct" — the user never typed an address, they tapped a saved link. "Please try again later" — this page is gone; trying later will not bring it back. Users do not want correct advice; they want a useful road. Third, do not pretend nothing happened. Some sites dress their 404 page up as the home page, so users who open a dead link see the home page and think they tapped the wrong thing, or the site is broken. That is a "soft 404": search engines think the page is still alive, users think they took a wrong turn, and both sides are confused. If something is broken, say it is broken, say it clearly, and then show the road.

The tone can be light, but not too light. "Oops, this page moved away" is fine; three paragraphs of jokes are not — the user is looking for a magazine they want, and they are in no mood for jokes. Light means "do not frighten the user," not "make the user laugh." One sentence that explains, one button home, one box to search in — that beats three paragraphs of jokes.

4. Where dead links come from: one fix per cause, never one fix for all

Once the 404 page is written, treat the cause: where do dead links come from? There are only four causes, each needs a different fix, and one fix for all of them is wrong every time.

The first cause is a redesign that moved links: the site was rebuilt, articles moved from "/blog/123" to "/posts/123," and every old link died. Catch these with a 301 redirect — old links jump to the new ones automatically, and users never feel the break. The second cause is deleted content: an article deleted, a product taken down, an event over — the page is genuinely gone. Do not force these to the home page; give them a real 404 page that says "this page is gone" and recommends similar content — a product taken down gets three similar products recommended; a deleted article gets three articles from the same section. The third cause is a mistyped address: users type a web address by hand, miss a letter, add an extra slash. Catch these with the search box on the 404 page — they are one letter away from their target, and one search finds it. The fourth cause is a wrong link from another site: some other site quoted your link and copied it wrong. You cannot fix their quote, but you can put a search box and popular content on your 404 page, so people who follow the wrong link still find a road.

Of the four causes, the second is the easiest to miss: deleting content. Many teams delete the content and forget the links pointing to it — other articles on the site still link to it, search engines still list it, and users who follow those links hit nothing but dead ends. When you delete content, do two things as part of the same job: change or remove the links on your site that point to it, and give it a 301 or a dignified 404. Deleting content is not deleting one row of data; it is taking down a bridge, and when a bridge comes down, the people walking on it need another road.

5. Redirects: keep old links for at least 180 days, and know when to redirect and when not to

Redirects are the most useful tool for catching dead links, but used wrong they are worse than useless. There are three rules; remember them and you will not go wrong.

The first rule is to keep old links redirecting for at least 180 days. That number is a fictional example; the point is "have a stated retention period, and write it into the redesign checklist" — delete all old links on day one of a redesign, and the links in users' saved collections, in search engine indexes, and in other sites' references all die overnight. Within 180 days, search engines have time to update their indexes, users have time to update their saved links, and other sites have time to update their references. The second rule is to tell 301 and 410 apart: content that moved to a new home gets a 301 permanent redirect to the new link; content that is truly gone and never coming back gets a 410, telling search engines "this page is gone for good, stop coming back for it" — do not use a 301 to force deleted content onto the home page, or search engines will think the home page and the deleted page are the same thing, and users will think they tapped the wrong thing. The third rule is never to send the whole site to the home page: redirecting every old link to the home page to save effort means users who open a saved magazine link see the home page and think the site is broken. Map each link to its destination one by one; it is tedious, but it is the only correct way.

One more detail: redirect to the closest page, not a roughly related one. A magazine taken down goes to the list page for the same kind of magazine; a deleted article goes to the list page for the same section; a finished event goes to the events list page. Redirecting to the home page is the same as not redirecting — users want that magazine, not the home page.

6. Dead-link patrol: sweep the whole site once a month, and fix in order of how many people hit each one

With the 404 page and redirects done, dead links will still keep appearing: other sites change their references, partners change their links, and your own team misses one when deleting content. So dead links need regular patrols; do not wait for users to report them.

The practice is to sweep the whole site once a month. The fictional example numbers in this guide are: out of 1,000 outbound links, about 17 go dead each month. These numbers are fictional; the point is "have a fixed patrol rhythm and a rough sense of how many links fail" — sweep once a month, and fix what you find in order of how many people hit each dead link: a dead link that 100 people hit every day gets fixed today; one that a single person hits in a month can wait until next month. Do not fix in the order you found them; fix in order of how many people hit them — the most-hit first, the least-hit last. The tools do not need to be fancy: crawl internal links with a crawler, run outbound links through a bulk checker, and read the crawl-error report in the search console. Those three together are a complete dead-link list.

Patrols have one corner that is easy to miss: the on-site search page with no results. A user searches the site for a word, finds nothing, and the page they see is the same as a 404 — what they wanted is not there. Build the no-results page with the same three pieces as a 404 page: say clearly "no matching content was found," offer a way home, and suggest a few popular searches or recommended items. Searching and finding nothing feels exactly like opening a dead link — in both cases, the user has walked into a dead end.

7. Do not treat the 404 page as a traffic entrance: three lines never to cross

The better a 404 page works, the more tempting it is to use it as a traffic entrance — ads on it, promotions on it, download buttons on it. These are three lines, and none of them should be crossed.

The first line is no ads or promotions: the user is looking for a magazine, and pushing an unrelated event at them will not get a click — it will only make them feel the site wants to make money even out of an error. The second line is no automatic redirects: a user opens a dead link and three seconds later the page drags them to the home page — before they have even understood what happened, they have been moved, and they will think they tapped the wrong thing, or the site is broken. An automatic redirect takes away the user's choice and tells them nothing about what happened. The third line is never pretend nothing happened: some sites return a 200 status code for a 404, making search engines think the page is still alive — that is a soft 404, and search engines will eventually discover the page holds nothing, and the whole site's indexing will suffer. When something is broken, return a 404; the status code must be honest and the page must be dignified. Both matter.

The reason behind all three lines is one sentence: the 404 page meets users at their most fragile — what they wanted is gone and they are already annoyed — and pushing a promotion, dragging them away, or lying to search engines at that moment is pushing them once more when they are already down. The dignified approach is the opposite: say it clearly, show the road, and do not disturb them. Users remember a site whose error pages are trustworthy, and they come back.

8. Pre-launch checklist

Tick every item on this list before shipping any 404 page feature. First, the three pieces: say it clearly ("This page can't be found — the link may have moved, or the content may have been taken down"), show the way home (a clear "Back to home" button), and offer a way to keep looking (an on-site search box or three to five recommended links, never more than 5); the order is say it first, then show the way home, then offer a way to keep looking. Second, the words: write "This page can't be found," never "Error 404" or "The page you requested does not exist"; never write correct nonsense like "Please check that the web address you entered is correct" or "Please try again later"; when something is broken, say it is broken — no soft 404s; the tone can be light, but not three paragraphs of jokes. Third, the causes: a redesign that moved links gets a 301, deleted content gets a dignified 404 plus similar recommendations, mistyped addresses are caught by the search box, and wrong links from other sites are caught by the search box and popular content; when deleting content, change or remove the links on your site that point to it as part of the same job. Fourth, redirects: keep old links for at least 180 days (fictional example), use a 301 when content moved to a new home and a 410 when it is truly gone, never force deleted content onto the home page with a 301, never send the whole site to the home page, and redirect to the closest page, not a roughly related one. Fifth, patrols: sweep the whole site once a month, about 17 out of 1,000 outbound links go dead each month (fictional example), fix in order of how many people hit each dead link, and build the no-results search page with the same three pieces. Sixth, the three lines: no ads or promotions on the 404 page, no automatic redirects, and never return a 200 status code to pretend nothing happened; users are at their most fragile when they hit a 404, and pushing a promotion, dragging them away, or lying to search engines at that moment is pushing them once more when they are already down.

Six pitfalls, once more. First, do not leave a single line of "404 Not Found": that is not a 404 page, it is a wall; 91 out of 100 people will close it immediately (fictional example). Second, do not write "The page you requested does not exist": it amounts to saying "you took a wrong turn," and users did nothing wrong. Third, do not force deleted content onto the home page: users who open a saved magazine link and see the home page will think the site is broken. Fourth, do not delete all old links on day one of a redesign: keep them for at least 180 days (fictional example), so search engines, users, and other sites have time to update. Fifth, do not wait for users to report dead links: sweep once a month and fix in order of how many people hit each one. Sixth, no ads, no automatic redirects, and no soft 404s on the 404 page: users are looking for something and already annoyed; pushing a promotion, dragging them away, or lying to search engines at that moment is pushing them once more when they are already down.

404-page funnel (fictional sample): 100 visits hit a 404, 78 read the page copy, 61 tapped search or a recommended link, 44 found what they wanted, 29 stayed to keep browsing

Back to Xiao Man. She still uses OldBookstall — not because it has never shown a 404 again, but because it showed one again last month: she opened an old link, and the page read "This page can't be found — the link may have moved, or the content may have been taken down," with a clear button below that read "Back to home," and beneath it a search box and three recommendations — one of them the new issue in the same series as the magazine she wanted. She tapped it, found it, and bought it. The whole thing cost her one decision. No refreshing three times, no deleting saved links, no feeling that the magazine was gone for good. That is what a 404 page is for: sooner or later a user will open a page in your app that no longer exists, and before that happens, the product's job is not to guarantee links never break — links will break one day — it is to say clearly "this page is gone, but the road is still here," giving them a button home, a box to search in, and three links they can tap, so they understand at a glance, move on in one tap, and keep looking for what they wanted as if nothing had ever broken.

Views 5Comments 0

Comments (0)

ME
0/1000
Loading comments...
Browse projectsPublish your project

Related articles

Real photo: a laptop, tablet, and phone on a wooden table showing the same green-leaf website, the phone view with navigation in one column, a potted plant nearby
Guide
Squashed on phones? Responsive layout and media queries, explained plainly

One page should stand up on a phone, a tablet, and a computer. This guide follows MDN's Responsive web design, Using media queries, and the viewport meta reference: fluid HTML, the viewport tag, fluid grids and max-width, images that never burst their container, media query syntax, breakpoints set by content, mobile first, responsive type, testing capability instead of width, and a pre-launch checklist.

Mobile AppsDesign ExperienceFrontend Engineering
Real photo: a bank of light gray metal filing cabinets with one drawer pulled open, revealing rows of hanging file folders inside
Guide
A real database inside the browser: IndexedDB local storage, explained plainly

localStorage only stores strings and has no indexes. IndexedDB is a real database in the browser: structured data, far larger capacity, indexes, and transactions. Following MDN's Using IndexedDB, IDBDatabase, and IDBObjectStore: the five-step routine, opening, upgrades, keys, indexes, transactions, add versus put, get, cursors, ranges, and multi-tab upgrades.

Tool TipsData WorkflowsFrontend Engineering
Real photo: hands typing on a MacBook Pro showing JavaScript code that changes HTML content, with a white mouse, papers, and binders on a white desk
Guide
Functions without the confusion: JavaScript functions, parameters, and arrow functions, explained plainly

You already call functions every day; this guide names what you have been doing. Following MDN's Functions, Arrow function expressions, and Rest parameters: declarations versus expressions, parameters and arguments, default values, rest parameters, spread syntax, return values, arrow function shorthand, the this trap, callbacks, and scope.

Tool TipsFrontend EngineeringAI Coding