status-colors-and-errors
Status Colours and Error Design
Keep the Colour Set Small
Every status colour added to a system is a cognitive burden on the user. They must learn what each colour means, remember it, and interpret it correctly under stress — which is exactly when errors occur.
The minimal set that covers almost everything:
| Colour | Semantic meaning | Always means |
|---|---|---|
| Red | Error / failure / destructive | Something went wrong, or this action cannot be undone |
| Orange / Amber | Warning | Something needs attention before proceeding |
| Green | Success / positive | Action completed, state is healthy |
| Blue | Info / neutral status | Informational, no action required |
Rule: each colour maps to exactly one meaning across the entire product. If orange means "warning" in one component and "pending" in another, the system breaks down.
When in doubt, cut the colour — neutral grey communicates status without semantic weight, and neutral is better than a misused semantic colour.
Orange Is Always a Warning
Orange (amber) carries a specific signal: pay attention, something may go wrong. Do not use it for:
- Neutral states (use grey)
- Progress or pending (use blue or a spinner)
- Informational content (use blue)
- Branding or decorative purposes inside status indicators
If orange appears in the UI, the user should immediately know it requires their attention.
Errors Should Be Recoverable
The worst error is one the user cannot recover from. Design every error state with a path forward.
Error message anatomy
Every error should answer three questions:
- What went wrong? — plain language, no error codes
- Why did it happen? — if useful and known
- What should the user do next? — specific, actionable
❌ "Error 500"
❌ "Something went wrong"
✓ "We couldn't save your changes. Check your connection and try again."
✓ "This email is already in use. Sign in instead, or use a different email."
Recovery actions
- Always provide a retry button for transient failures (network errors, timeouts)
- For validation errors, point directly to the problematic field
- For destructive actions that failed, reassure the user nothing was lost
- For session expiry, redirect to login and return the user to where they were
Prevent Large Errors Before They Happen
The most damaging errors — data loss, irreversible actions, broken state — should be prevented at the design level, not handled after the fact.
- Confirm before irreversible actions: "Delete this project and all 47 tasks? This cannot be undone."
- Disable unavailable actions rather than letting users trigger them and hit an error
- Autosave where possible so a browser crash or accidental close does not destroy work
- Optimistic UI with rollback: show the success state immediately, silently retry on failure, surface an error only if the retry also fails
Levels of Severity — Use Sparingly
Not every problem is equal. Match the visual weight of the feedback to the severity.
| Severity | Pattern | When to use |
|---|---|---|
| Blocking error | Full-page error state or modal | App cannot continue, user must act |
| Inline error | Red text below a field | Form field validation failure |
| Toast / snackbar | Temporary notification, bottom of screen | Transient failure the user should know about but can dismiss |
| Alert banner | Persistent bar at top of section | Ongoing issue affecting the current context |
| Empty state | Illustrated or descriptive empty screen | No data yet — use as an opportunity for guidance, not just a blank |
Avoid showing multiple simultaneous error types at once — one clear message is more useful than three overlapping alerts.
Review Checklist
- Does the product use four or fewer semantic status colours?
- Does each colour mean exactly one thing, used consistently everywhere?
- Is orange/amber reserved exclusively for warnings?
- Does every error message state what went wrong and what to do next?
- Do all transient errors (network, timeout) have a retry action?
- Are irreversible destructive actions protected by a confirmation step?
- Is autosave or draft recovery available for long-form or complex inputs?
- Are multiple simultaneous error states avoided?
Common Anti-Patterns
| Anti-pattern | Problem | Fix |
|---|---|---|
| "Something went wrong" with no action | User is stuck with no path forward | Add specific cause and a retry or contact link |
| Orange used for "pending" and "warning" simultaneously | Colour loses its meaning | Orange = warning only; use blue or spinner for pending |
| Five or more status colours (red, orange, yellow, teal, purple…) | User must learn and remember a complex legend | Cut to the minimum: red, orange, green, blue |
| Inline validation only on submit | User discovers all errors at once | Validate on blur (leaving a field) for immediate feedback |
| No confirmation on delete | Users accidentally delete data | Require explicit confirmation for all irreversible actions |
More from dembrandt/dembrandt-skills
nielsen-usability-heuristics
UI design and review should apply Nielsen's 10 Usability Heuristics — the foundational principles for evaluating and improving usability. Use when auditing an interface, designing interaction flows, writing error messages, or reviewing any UI for usability issues.
45form-design
Forms have three layers of guidance: helper text below the input explains what to enter, placeholder shows the expected format, and validation confirms correctness. Real-time validation for complex inputs. Submit enables only when the form is valid. Use when designing or reviewing any form, input field, or data entry UI.
44color-mode-and-theme
Choose light, dark, or combined color mode deliberately based on brand tone and user context. Offer a theme selector only when user control genuinely matters — enterprise tools, data-heavy UIs, or extended-use applications. Use when defining the base color palette, designing a design system, or deciding whether to build dark mode support.
43generate-ui-from-brand
Pipeline skill — turns a URL or DESIGN.md into a concrete UI structure with decisions already made. Extracts live design tokens, normalizes them into a semantic system, applies UX principles, and outputs an actionable UI spec. Use when building UI for an existing brand from scratch, auditing a design system, or refactoring visual inconsistency.
42scroll-areas
Scroll areas inside a layout should be avoided wherever possible. When unavoidable, allow only one scroll axis at a time and always keep the user in control. Use when designing layouts, data tables, panels, or any component that might introduce an inner scroll container.
42micro-interactions
Micro-interactions are small, purposeful animations and responses that reward the user and make the interface feel alive — an animated icon, a satisfying toggle, a subtle reveal. Borrowed from the natural world, they add delight without distraction. Use when designing interactive components, success states, toggles, loaders, or any moment worth celebrating.
42