Skip to content
Back to skills

Error Pages

ASecurity

Create custom 404 and 500 error pages with brand styling. Use at project end before release. Triggers on "404", "error pages", "not found", "500 error".

  • 666 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added February 8, 2026
tools

Works with

  • cli

Security analysis

A100/100

Scanned February 12, 2026

npx -y skills add majiayu000/claude-skill-registry --skill error-pages --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Error Pages?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Error Pages
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/majiayu000-error-pages/badge)](https://www.skillsdirectory.com/skills/majiayu000-error-pages)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: error-pages
description: Create custom 404 and 500 error pages with brand styling. Use at project end before release. Triggers on "404", "error pages", "not found", "500 error".
---

# Error Pages

Create branded 404 and 500 error pages.

## Workflow

1. Create app/not-found.tsx (404)
2. Create app/error.tsx (500)
3. Match brand styling from globals.css
4. Add i18n support

## 404 Page (not-found.tsx)

Create at `app/not-found.tsx`:

```tsx
import Link from 'next/link'

export default function NotFound() {
  return (
    <div className="min-h-svh flex items-center justify-center bg-background">
      <div className="container text-center">
        <h1 className="mb-4">404</h1>
        <p className="text-muted-foreground mb-8">
          Diese Seite wurde nicht gefunden.
        </p>
        <Link href="/" className="btn btn-primary">
          Zurück zur Startseite
        </Link>
      </div>
    </div>
  )
}
```

## 500 Page (error.tsx)

Create at `app/error.tsx`:

```tsx
'use client'

export default function Error({
  error,
  reset,
}: {
  error: Error & { digest?: string }
  reset: () => void
}) {
  return (
    <div className="min-h-svh flex items-center justify-center bg-background">
      <div className="container text-center">
        <h1 className="mb-4">Fehler</h1>
        <p className="text-muted-foreground mb-8">
          Ein unerwarteter Fehler ist aufgetreten.
        </p>
        <button onClick={reset} className="btn btn-primary">
          Erneut versuchen
        </button>
      </div>
    </div>
  )
}
```

## i18n Support

Add to messages/de.json and messages/en.json:

```json
{
  "error": {
    "404": {
      "title": "404",
      "message": "Diese Seite wurde nicht gefunden.",
      "cta": "Zurück zur Startseite"
    },
    "500": {
      "title": "Fehler",
      "message": "Ein unerwarteter Fehler ist aufgetreten.",
      "cta": "Erneut versuchen"
    }
  }
}
```

## Checklist

- [ ] app/not-found.tsx created
- [ ] app/error.tsx created
- [ ] Brand styling applied
- [ ] i18n text added
- [ ] 404 page tested (visit /nonexistent-page)

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.