Content
Errors
Say what happened, then what to do about it.
Two lines, in that order.
✗ Don't — "You entered an invalid query."
✓ Do — "No results match these filters. Clear the date range to widen the search."
Line one is the fact. What broke, and what it affects. Name the thing, not the layer it failed in.
Line two is the action. What the reader can do now, or who can. If there is nothing to do, say what happens next and when.
Never blame the reader. The filter returned nothing; the person did not fail. Avoid "you entered", "invalid" and "illegal".
No dead ends. An error with no next step is an unfinished error.