---
title: "Link/redirect to a route that does not exist (next/unknown-route)"
description: "The target path matches no app route (page, route handler, metadata route) and no file in public/, so it 404s."
url: http://localhost:4173/rules/next/unknown-route
updated: 2026-11-11
---

# Link/redirect to a route that does not exist

> `next/unknown-route` is a vetd rule. It flags: Link/redirect to a route that does not exist. It runs on every `check`, together with the TypeScript check.

| Fact | Value |
| --- | --- |
| Rule id | `next/unknown-route` |
| Severity | error or warning |
| Group | Server and client boundaries |
| Tags | correctness, nextjs-16 |

## Why it matters

The target path matches no app route (page, route handler, metadata route) and no file in public/, so it 404s.

## How to fix it

Fix the path, or create the route. If the proxy/middleware serves it, ignore this finding.

## References

- [Link Component](https://nextjs.org/docs/app/api-reference/components/link), Next.js
- [page.js](https://nextjs.org/docs/app/api-reference/file-conventions/page), Next.js
- [Linking and Navigating](https://nextjs.org/docs/app/getting-started/linking-and-navigating), Next.js

## Related rules

- [`next/internal-anchor`](http://localhost:4173/rules/next/internal-anchor.md)

## Get this text from vetd

MCP: call `explain` with `{ "diagnosticId": "next/unknown-route" }`. CLI: `npx vetd explain next/unknown-route`.

---

[All 92 rules](http://localhost:4173/rules.md) · Previous: [`next/route-params`](http://localhost:4173/rules/next/route-params.md) · Next: [`next/client-env`](http://localhost:4173/rules/next/client-env.md)
