Snackbar

Brief confirmations that never block the work.

v1.0.0·Updated Jul 8, 2026 · 10:45
Live Demo · Fully Interactive
Success, error and info · brief and non-blocking
Changes saved.
Couldn't save. Try again.
A new version is available.
Configuration
Variant
Action
Close
Message
Changes saved.
<Snackbar variant="success" action="Undo" dismissible duration={4000} />
Behavior · The Engineering Contract
Prop / eventTypeNotes
variantsuccess · error · info · warnIcon and accent colour
action{ label, onClick }One inline warm action, like Undo
durationnumberAuto-dismiss ms; pauses on hover / focus
dismissiblebooleanShows the manual close ×
positionbottom-center · bottom-rightWhere the stack anchors

A Snackbar confirms briefly and never blocks. For a message that needs a decision use a Modal; for persistent inline emphasis use a Callout.

Anatomy
Changes saved.Undo
1IconStatus colour matching the variant.
2MessageOne short line; no headings.
3Action / closeAt most one action, plus a dismiss.
Do's and Don'ts
✓ Do
Saved.Undo

One line, one action. Confirm and let the reader move on.

✕ Don't
Saved. Your changes to the document have been written to all three replicas and…

Don't write a paragraph. Long copy belongs in a Callout or Modal.

✓ Do
Couldn't save.Retry

Give errors a way forward. A Retry beats a dead end.

✕ Don't
Saved.UndoViewShare

Don't stack multiple actions. A toast holds one, at most.

In context: Examples
A · Save
Draft saved

Quiet confirmation after an autosave or explicit save.

B · Undo
Item deletedUndo

Reversible destructive actions with a short Undo window.

C · Error
Network errorRetry

Transient failures that the user can immediately retry.

Measurements & Tokens
TokenValueRole
--snack-bg#1A1B1FBar surface
--snack-shadow0 14px 34px /.45Lift off the page
--snack-success#4FCE8BSuccess icon
--snack-error#F2777BError icon
--snack-action#FF9D45Inline action label
--snack-duration4000msDefault auto-dismiss
Code
<div class="o-snack o-snack--success" role="status">
  <span class="o-snack__icon"><CheckIcon /></span>
  <span class="o-snack__text">Changes saved.</span>
  <button class="o-snack__action">Undo</button>
  <button class="o-snack__close" aria-label="Dismiss">×</button>
</div>