Errors provide contextual and actionable feedback to help users resolve failures and avoid future complications.
Problem Statement
Errors cause disappointment and frustration and we should prevent them when possible. When errors do happen, our feedback should be thoughtful and exemplify the conversations we want to have with our users.
System Errors
Entire Page or System is Down
If a full page or system is down, apologize, let the user know what’s going on, and tell them how long it might take to resolve the issue.
Restricted Access
If a user can’t access certain information, tell them why, or hide the component entirely if it’s not pertinent to their role. Provide a way to resolve access issues, if it’s possible.
User Errors
Page-Level Validation
When a user submits a form, if multiple required fields are not completed, page-level validation will inform the user to complete those required fields. The combined field-level validations should further describe the error in detail. See Notifications, Tooltips and Forms for more info.
Field-Level Validation
If a user enters an input incorrectly or fails to take proper action, alert them with red, in-line error messaging. Ideally, this messaging would show as the user types. See Input states for details.
Preventative Measures
Deactivating Controls
Deactivate the primary action button on the page until all required information has been provided.
Offer helper text in tooltips if user must take action before a page is rendered. See Buttons and Tooltips for more information.
Prevent errors ahead of time by identifying required/optional fields. See Forms for more information.
Character counters set users' expectations for how much content to enter, including any limits on characters.
Guidelines
Editorial
Never make a user feel foolish, guilty or patronized. Use natural language to help them get out of whatever jam they’re in.
Use full sentences with punctuation.
Acknowledge what is keeping a user from proceeding, but don’t make them feel like they did something wrong.
If we are the reason they can’t proceed, apologize.
Provide a user at least one way to resolve the problem.
Write it as if you were telling a friend how to resolve an issue.
If an error has the potential to repeat, tell a user what they should do, i.e., “If the site continues to not recognize your account, email us at ___.”