# Confirming vs undoing a destructive action

> People delete things by mistake, and asking “are you sure?” every time teaches them to click yes without reading.

Area: Deleting and undoing. Evidence behind the answer: Moderate. Last checked November 11, 2026.
Page: https://uxreference.com/deleting/confirm-vs-undo

## The answer

Act at once and offer undo. Ask “are you sure?” only when it truly cannot be undone and is rare.

- **Moderate.** If the action can be undone, do it at once and offer Undo. Don’t ask first. (https://uxreference.com/deleting/confirm-vs-undo#rule-3)
- **Moderate.** Ask for confirmation before an action that can’t be undone and is rare or serious. (https://uxreference.com/deleting/confirm-vs-undo#rule-5)

## The problem

People delete, send and overwrite things by mistake, and asking "are you sure?" every time teaches them to agree without reading.

## How to decide

If it can be undone, or you can make it so, act and offer undo. If it truly cannot be undone and is rare, ask first, name what will be lost, and label the control with the action. Add typed confirmation only when the damage would be wide. Do not confirm routine actions.

## Every rule

Each rule has a grade: Settled (required by WCAG AA or law, or replicated research), Strong, Moderate, Weak, or Unsettled (use the stated default until the evidence settles).

### In every case

#### Rule 1. Settled, WCAG AA

Where an action deletes or changes a person's stored data, or commits them legally or financially, provide at least one safeguard. Make it reversible, or check the input and let them correct it, or let them review and confirm before it is final.

- Applies when: The action commits the person legally or financially, or deletes or changes their stored data.
- Based on: Standard or law
- Depends on: What a mistake costs
- Principle: Prevent errors

Why: Required by WCAG 2.2 at level AA. Both reopened and checked.

Sources: [Understanding SC 3.3.4 Error Prevention (Legal, Financial, Data) (Level AA)](https://www.w3.org/WAI/WCAG22/Understanding/error-prevention-legal-financial-data.html)

Link: https://uxreference.com/deleting/confirm-vs-undo#rule-1

#### Rule 2. Settled, WCAG AA

When a result message such as "Deleted" appears and focus does not move to it, expose it so assistive technology announces it.

- Applies when: A result message is shown without a focus change.
- Based on: Standard or law
- Principle: Work for everyone

Why: Required by WCAG 2.2 at level AA. Both reopened and checked.

Sources: [Understanding SC 4.1.3 Status Messages (Level AA)](https://www.w3.org/WAI/WCAG22/Understanding/status-messages.html)

Link: https://uxreference.com/deleting/confirm-vs-undo#rule-2

### When the action can be undone, or could be made to

#### Rule 3. Moderate

If the action can be undone, do it at once and offer undo. Do not ask for confirmation first.

- Applies when: The action can be undone.
- Based on: Convention
- Depends on: Whether it can be undone
- Principle: Help people recover from errors

Why: Apple, Primer, Automattic and three essays agree, and WCAG accepts reversibility as a safeguard. Nielsen's NN/g article treats undo as a complement to confirmation, not a replacement, so it is not counted here. No study compares the two approaches, so convention caps it at 3.

Sources: [Human Interface Guidelines - Alerts](https://developer.apple.com/design/human-interface-guidelines/alerts.md); [Delete scenario pattern (Primer)](https://primer.style/product/scenario-patterns/delete); [Destructive actions (Automattic Design System)](https://system.automattic.design/foundations/destructive-actions/); [NN/g article on user mistakes (exact headline not captured)](https://www.nngroup.com/articles/user-mistakes/); [Never Use a Warning When You Mean Undo](https://alistapart.com/article/neveruseawarning); [How To Manage Dangerous Actions In User Interfaces](https://www.smashingmagazine.com/2024/09/how-manage-dangerous-actions-user-interfaces); [Understanding SC 3.3.4 Error Prevention (Legal, Financial, Data) (Level AA)](https://www.w3.org/WAI/WCAG22/Understanding/error-prevention-legal-financial-data.html)

Link: https://uxreference.com/deleting/confirm-vs-undo#rule-3

#### Rule 10. Moderate

Keep deleted things recoverable for a period where the product can, so that deletion can be undone later as well as at once.

- Applies when: The product can hold deleted data.
- Based on: Convention
- Principle: Help people recover from errors

Why: NN/g and three essays, and WCAG lists recovery of deleted information as a technique. Rated 3.

Sources: [Confirmation Dialogs Can Prevent User Errors - If Not Overused](https://www.nngroup.com/articles/confirmation-dialog/); [Never Use a Warning When You Mean Undo](https://alistapart.com/article/neveruseawarning); [Are You Sure? Versus Undo: Design and Technology](https://uxmatters.com/mt/archives/2020/03/are-you-sure-versus-undo-design-and-technology.php); [How To Manage Dangerous Actions In User Interfaces](https://www.smashingmagazine.com/2024/09/how-manage-dangerous-actions-user-interfaces); [Understanding SC 3.3.4 Error Prevention (Legal, Financial, Data) (Level AA)](https://www.w3.org/WAI/WCAG22/Understanding/error-prevention-legal-financial-data.html)

Link: https://uxreference.com/deleting/confirm-vs-undo#rule-10

#### Rule 12. Weak

Do not make a message that disappears by itself the only place undo is offered. Keep undo available somewhere that stays.

- Applies when: Undo is offered in a message that times out.
- Based on: Reasoned, not tested
- Principle: Help people recover from errors

Why: One expert essay plus my reading of WCAG 2.2.1, which does not mention undo. Inference, so capped at 2.

Sources: [A toast to a11y toasts](https://scottohara.me/blog/2019/07/08/a-toast-to-a11y-toasts.html); [Understanding SC 2.2.1 Timing Adjustable (Level A)](https://www.w3.org/WAI/WCAG22/Understanding/timing-adjustable.html)

Link: https://uxreference.com/deleting/confirm-vs-undo#rule-12

#### Rule 13. Unsettled

How long an undo offer should last is unsettled.

- Applies when: Undo is offered for a limited time.
- Based on: Convention
- Principle: Help people recover from errors

Why: No evidence either way. Rated 1.

Sources: [Send or unsend Gmail messages](https://support.google.com/mail/answer/2645922?hl=en); [Are You Sure? Versus Undo: Design and Technology](https://uxmatters.com/mt/archives/2020/03/are-you-sure-versus-undo-design-and-technology.php); [Understanding SC 3.3.4 Error Prevention (Legal, Financial, Data) (Level AA)](https://www.w3.org/WAI/WCAG22/Understanding/error-prevention-legal-financial-data.html)

Link: https://uxreference.com/deleting/confirm-vs-undo#rule-13

### When it can’t be undone

## Accessibility requirements

- WCAG 2.2, 3.3.4 Error Prevention (Legal, Financial, Data) (AA): one of reversible, checked, or confirmed. Recovery and confirmation are both listed as sufficient for deletion. The criterion says it is not meant to require confirmation of every save. (https://www.w3.org/WAI/WCAG22/Understanding/error-prevention-legal-financial-data.html)
- WCAG 2.2, 4.1.3 Status Messages (AA): result messages that do not take focus must be exposed for announcement. (https://www.w3.org/WAI/WCAG22/Understanding/status-messages.html)
- WCAG 2.2, 2.2.1 Timing Adjustable (A): time limits must be adjustable or extendable. The Understanding document does not mention undo, so applying it to an undo offer is inference ([rule 12](https://uxreference.com/deleting/confirm-vs-undo#rule-12)). (https://www.w3.org/WAI/WCAG22/Understanding/timing-adjustable.html)
- WAI-ARIA Authoring Practices, modal dialog and alert dialog patterns: focus stays in the dialog, Escape closes it, focus returns to the opener. It suggests, without requiring, initial focus on the least destructive control for irreversible steps. (https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/)
- Also likely to apply: 3.3.6 Error Prevention (All) (AAA). (https://www.w3.org/WAI/WCAG22/Understanding/error-prevention-all.html)

## Common mistakes

- Confirming everything. Field data on browser security warnings shows the most frequent warnings were clicked through fastest and most often ([Alice in Warningland: A Large-Scale Field Study of Browser…](https://static.googleusercontent.com/media/research.google.com/en//pubs/archive/41323.pdf)). That is a neighboring kind of dialog, not delete confirmation.
- "Are you sure?" with "Yes" and "No". Does not say what will happen ([Confirmation Dialogs Can Prevent User Errors - If Not…](https://www.nngroup.com/articles/confirmation-dialog/); [Human Interface Guidelines - Alerts](https://developer.apple.com/design/human-interface-guidelines/alerts.md)).
- Undo offered only in a message that vanishes after a few seconds ([rule 12](https://uxreference.com/deleting/confirm-vs-undo#rule-12)).
- Confirmations worded to make the person feel bad for leaving, and cancellation flows padded with extra confirmations. Link to the dark patterns track (confirmshaming, obstruction) when it is written.
- Dark patterns that work against this entry's rules: [[Accidental and unauthorized charges](https://uxreference.com/dark-patterns/unauthorized-charges)](../dark-patterns/[Accidental and unauthorized charges](https://uxreference.com/dark-patterns/unauthorized-charges)).

## Still open

- No study was found that compares confirmation with undo for destructive actions. Every source that prefers undo argues from reasoning or from habituation research on other kinds of dialog.
- Routine actions that cannot be undone, such as sending a message. Confirmation trains click-through; the sources offer a short delay before the action takes effect, but no evidence for how long.
- Undo duration. Google's help page gives 5 to 30 seconds, set by the user, for undoing a sent email, without reasons. No source gives evidence for any length.
- Initial focus. Primer puts it on Cancel; Apple says Cancel should not be the default and suggests no default so that people read; Carbon's general rule would put it on the primary control.
- Should Escape always cancel? One small system blocks it to force a choice.

## Related problems

- [Confirmation dialogs](https://uxreference.com/dialogs/confirmation): Confirm rarely, label the buttons with what they do, and for severe actions make people engage with the detail.
- [Modal dialogs](https://uxreference.com/dialogs/modal): Use a modal only when people must respond before anything else, and only after their own action.
- [Focus management on open and close](https://uxreference.com/dialogs/focus-management): Move focus into a dialog when it opens, and back to the control that opened it when it closes.
- [Toasts and notifications](https://uxreference.com/feedback/toasts): Use messages that vanish by themselves only for things people can afford to miss.
- [Time limits](https://uxreference.com/accessibility/time-limits): Avoid time limits. Where one is needed, warn before it ends and let people extend it.

## Sources

- [Understanding SC 3.3.4 Error Prevention (Legal, Financial, Data) (Level AA)](https://www.w3.org/WAI/WCAG22/Understanding/error-prevention-legal-financial-data.html). W3C WAI, n.d., normative standard.
- [Understanding SC 4.1.3 Status Messages (Level AA)](https://www.w3.org/WAI/WCAG22/Understanding/status-messages.html). W3C WAI (WCAG Working Group), n.d., normative standard (Understanding document is informative).
- [Human Interface Guidelines - Alerts](https://developer.apple.com/design/human-interface-guidelines/alerts.md). Apple Inc., 2026, component documentation.
- [Delete scenario pattern (Primer)](https://primer.style/product/scenario-patterns/delete). GitHub (Primer design system), n.d., component documentation.
- [Destructive actions (Automattic Design System)](https://system.automattic.design/foundations/destructive-actions/). Automattic (Design System), n.d., component documentation.
- [NN/g article on user mistakes (exact headline not captured)](https://www.nngroup.com/articles/user-mistakes/). Page Laubheimer, Nielsen Norman Group, 2015, expert essay with annotated screenshots.
- [Never Use a Warning When You Mean Undo](https://alistapart.com/article/neveruseawarning). Aza Raskin, A List Apart (issue 241), 2007, expert opinion.
- [How To Manage Dangerous Actions In User Interfaces](https://www.smashingmagazine.com/2024/09/how-manage-dangerous-actions-user-interfaces). Victor Ponamariov, Smashing Magazine, 2024, expert opinion.
- [Confirmation dialog - guidelines and accessibility (Primer)](https://primer.style/product/components/confirmation-dialog/guidelines). GitHub (Primer design system), n.d., component documentation.
- [Alert dialog (HealthMetrics design system)](https://designsystem.healthmetrics.com/components/overlays/alert-dialog). HealthMetrics design system (publisher organization not verified beyond the domain), n.d., component documentation.
- [Confirmation Dialogs Can Prevent User Errors - If Not Overused](https://www.nngroup.com/articles/confirmation-dialog/). Jakob Nielsen, Nielsen Norman Group, 2018, expert critique with examples.
- [Alice in Warningland: A Large-Scale Field Study of Browser Security Warning Effectiveness](https://static.googleusercontent.com/media/research.google.com/en//pubs/archive/41323.pdf). Devdatta Akhawe, Adrienne Porter Felt, 2013, field telemetry study (Chrome and Firefox).
- [You've been warned: An empirical study of the effectiveness of web browser phishing warnings](https://css.csail.mit.edu/6.566/2012/readings/youve-been-warned.pdf). Serge Egelman, Lorrie Faith Cranor, Jason Hong, 2008, between-subjects lab study with deception (told it was an online shopping study; spear-phishing emails sent after purchases).
- [From Warning to Wallpaper: Why the Brain Habituates to Security Warnings and What Can Be Done About It](https://scholarsarchive.byu.edu/cgi/viewcontent.cgi?article=2987&context=facpub). Bonnie Anderson, Anthony Vance, C. Brock Kirwan, Jeffrey L. Jenkins, David Eargle, 2016, fMRI experiment plus mouse-tracking experiment.
- [Improving Security Decisions with Polymorphic and Audited Dialogs](https://cups.cs.cmu.edu/soups/2007/proceedings/p76_brustoloni.pdf). José Carlos Brustoloni, Ricardo Villamarín-Salomón, 2007, within-subject lab role-play in a modified Thunderbird client (SOUPS 2007).
- [carbon-2025-modal-danger](https://carbondesignsystem.com/components/modal/usage/). n.d., component documentation.
- [Confirm a destructive action (Government of Alberta design system)](https://v2.design.alberta.ca/examples/confirm-a-destructive-action). Government of Alberta, n.d., component documentation.
- [Confirm an action (pattern, Experimental)](https://design-patterns.service.justice.gov.uk/patterns/confirm-an-action/). Ministry of Justice (UK), MOJ Design System, 2026, component documentation.
- [Modal design guidelines (PatternFly)](https://patternfly.org/components/modal/design-guidelines). Red Hat (PatternFly), n.d., component documentation.
- [Modal web component (Shopify App Home)](https://shopify.dev/docs/api/app-home/latest/web-components/overlays/modal.md). Shopify, n.d., component documentation.
- [apg-2026-dialog-modal](https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/). n.d., authoring guidance, non-binding (APG is not a standard).
- [Your Attention Please: Designing security-decision UIs to make genuine risks harder to ignore](https://microsoft.com/en-us/research/wp-content/uploads/2016/02/a6_Bravo-Lillo.pdf). Cristian Bravo-Lillo, Lorrie Faith Cranor, Julie Downs, Saranga Komanduri, Robert W. Reeder, Stuart Schechter, Manya Sleeper, 2013, three between-subjects online experiments with a deceptive task.
- [Are You Sure? Versus Undo: Design and Technology](https://uxmatters.com/mt/archives/2020/03/are-you-sure-versus-undo-design-and-technology.php). Steven Hoober, UXmatters, 2020, expert opinion with informal testing.
- [A toast to a11y toasts](https://scottohara.me/blog/2019/07/08/a-toast-to-a11y-toasts.html). Scott O'Hara, 2025, expert opinion reasoning from WCAG and ARIA.
- [Understanding SC 2.2.1 Timing Adjustable (Level A)](https://www.w3.org/WAI/WCAG22/Understanding/timing-adjustable.html). W3C WAI (WCAG Working Group), n.d., normative standard (Understanding document is informative).
- [Send or unsend Gmail messages](https://support.google.com/mail/answer/2645922?hl=en). Google (Gmail Help), n.d., product help documentation.

---
From Solved Problems in UX by Athen Pellicci, an evidence-graded reference of web interface problems. CC BY 4.0. https://uxreference.com/
