Sonner
A strong pick. 1st of 8 toasts and alerts.
Sonner is an opinionated React toast component with no dependencies. It became the most-installed toast library through shadcn/ui and AI app builders. It is still a strong pick for a new React app today, but upkeep has slowed to about one release a year. shadcn/ui now offers its own Base UI Toast, which may slow Sonner's growth.
Best for: React and Next.js teams that want polished toasts from one toast() call, with little setup.
Scores
Overall7.7
How strongly do we recommend it for a new project today?
Claude Opus 5.5: 7.5, likely 6.5 to 8.5
Sonner is the most widely used and best-reviewed React toast library, with excellent defaults and no dependencies. It falls short of 9 because maintenance has slowed to one release a year, it depends on one person, and shadcn/ui has started moving Base UI users to its own Toast. For most new React apps it is still the pick ahead of react-hot-toast and React-Toastify.
- blog.logrocket.com/react-toast-libraries-compared-2026: Recommended, with noted performance and accessibility limits
- pistack.xyz/posts/2026-08-22-react-toast-libraries-sonner-react-hot-toast-react-toastify-comparison: Pick for new apps
- github commitsLastYear: 5 commits in a year
- ui.shadcn.com/docs/changelog/2026-07-toast: shadcn/ui alternative for Base UI projects
GPT-6.2 Sol: 7.9, likely 6.7 to 8.9
Sonner is a strong greenfield choice for React teams that want ready-made toast interactions, especially with shadcn/ui. React-Toastify offers more queue and notification controls and has seen more recent maintenance activity, while SweetAlert2 better covers projects whose main need is alert dialogs. Sonner's slow release cadence and the reported regression in the latest patch keep it below default-choice territory across the category.
- ui.shadcn.com/docs/components/radix/sonner: shadcn/ui provides an installation path and a ready-made React wrapper.
- wingo-ui.com/blog/sonner-alternative-react-toast: Comparison documents Sonner's built-in interactions and React-Toastify's queue and history features.
- github.com/sweetalert2/sweetalert2: SweetAlert2 provides alert and confirmation dialogs.
- github commitsLastYear, releasesLastYear, and peers React-Toastify: Sonner shipped one release and recorded five commits, versus 27 commits for React-Toastify.
- github.com/emilkowalski/sonner/issues/786: The latest stable patch has a documented remount regression report.
Needed by many5.6
How many developers need a tool for this job?
Claude Opus 5.5: 6.0, likely 5.0 to 7.0
Most web apps need toasts, so the job is common. Sonner only works with React; other frameworks need ports such as Vue Sonner. That limits it to React developers, though they are a large group.
- github description: Describes itself as a toast component for React
- peers Vue Sonner: Other frameworks rely on separate ports
GPT-6.2 Sol: 5.2, likely 4.1 to 6.4
Short status messages are useful in many interactive web apps. Sonner serves React web apps and covers transient notifications, while alert dialogs require another component. The Stack Overflow survey establishes that React is common, but leaves the need for a standalone toast library unmeasured.
- survey.stackoverflow.co/2026/technology/data/web-framework: 41.5% of respondents to the web technology question reported extensive React use.
- sonner.emilkowal.ski: The product and examples focus on transient React notifications.
Helps a lot8.1
How well does it do the job for those who need it?
Claude Opus 5.5: 8.0, likely 7.0 to 9.0
It is full-featured: a promise API, stacking, multiple toasters, a headless mode, swipe to dismiss, a hotkey, types and no dependencies. Independent comparisons recommend it for new apps. LogRocket found it the slowest in a 50-toast stress test, with one colour-contrast issue and a close button that keyboard users could not reach. Restyling it is less open than with react-hot-toast.
- blog.logrocket.com/react-toast-libraries-compared-2026: Feature list, 9.2 kB gzipped, stress-test and accessibility findings, recommended
- pistack.xyz/posts/2026-08-22-react-toast-libraries-sonner-react-hot-toast-react-toastify-comparison: Recommended for new React and Next.js apps; not headless
- npm hasTypes, dependencies: Types included, 0 dependencies
GPT-6.2 Sol: 8.1, likely 7.0 to 9.1
The typed API covers promises, actions, swipe dismissal, and custom rendering with little setup. The small API and copyable examples give developers and coding agents a straightforward starting point. A measured build was about twice the size of react-hot-toast, and v2.0.8 users report regressions on remount and overflow on narrow screens. Those reports show concrete edge cases, with limited evidence about how often they occur in apps.
- npm latestVersion and hasTypes: Stable v2.0.8 ships TypeScript declarations.
- sonner.emilkowal.ski/toast: API examples cover promise flows, action buttons, and custom JSX.
- wingo-ui.com/blog/sonner-alternative-react-toast: Measured 9.6 kB minified and gzipped for Sonner versus 4.8 kB for react-hot-toast.
- github.com/emilkowalski/sonner/issues/786: A user reproduced toast replay on remount in v2.0.8 after upgrading from v2.0.7.
- github.com/emilkowalski/sonner/issues/789: A user reproduced toaster overflow on narrow viewports.
Holds up over time5.6
Will it still be a good choice in two years?
Claude Opus 5.5: 5.0, likely 3.5 to 6.5
The project had only 5 commits and 1 release (v2.0.8, August 2026) in the last year, with about a year since the release before it. It has 46 open pull requests, and the work rests mostly on one maintainer. Its API is stable and the user base is huge. But shadcn/ui made Base UI its default in July 2026 and shipped its own Toast for it, which may draw new projects away.
- github commitsLastYear, releasesLastYear, openPullRequests: 5 commits, 1 release, 46 open PRs
- github.com/emilkowalski/sonner/releases: v2.0.7 to v2.0.8 gap; fixes are small
- ui.shadcn.com/docs/changelog/2026-07-toast: New Base UI Toast in shadcn/ui
- ui.shadcn.com/docs/components/radix/sonner: Sonner is still offered for Radix and React Aria setups
GPT-6.2 Sol: 6.1, likely 4.7 to 7.7
The August patch merged community fixes for accessibility, modal layering, and dismissal. It was the only release in a year with five commits, while React-Toastify recorded 27. Recent community fixes are still pending, and the public record shows one listed npm maintainer and a personal sponsorship link. The pace of future fixes and continuity of funding remain uncertain.
- github commitsLastYear, releasesLastYear, and peers React-Toastify: Sonner recorded five commits and one release, versus 27 commits for React-Toastify.
- github.com/emilkowalski/sonner/releases/tag/v2.0.8: The August patch shipped fixes from several contributors.
- github.com/emilkowalski/sonner/actions: Community fixes were still awaiting action in November.
- socket.dev/npm/package/sonner: One npm maintainer is listed.
- github.com/emilkowalski/sonner/blob/main/FUNDING.yml: The funding file points to an individual sponsorship account.
Used widely7.5
How many use it, and is that growing?
Claude Opus 5.5: 8.5, likely 7.5 to 9.5
It had 230M downloads in 4 weeks, about 11 times React-Toastify, and up 9.5x in a year against a median ratio of 4.1. Much of that comes from shadcn/ui scaffolds, AI app builders and CI, so direct choices are far fewer. The ecosyste.ms dependents count of 701 looks like a data gap next to its peers' tens of thousands, so I give it little weight.
- npm downloadsLast4Weeks / downloadsSame4WeeksYearAgo: 230.4M vs 24.2M, ratio about 9.5
- peers downloadsLast4Weeks: react-hot-toast 20.4M, React-Toastify 20.5M
- dependents repos: 701, likely undercounted
- github stars: 13.2k stars
GPT-6.2 Sol: 6.5, likely 4.8 to 8.1
Four-week downloads grew 9.5 times year over year, well above the 4.1 times catalog median and the rates for React-Toastify and react-hot-toast. The 230 million installs include repeated builds and adoption through shadcn/ui scaffolding, whose Sonner component adds the package. Ecosyste.ms indexes only 701 repositories, far fewer than either React peer, while GitHub stars are similar. The gap between those signals leaves the number of projects choosing Sonner directly uncertain.
- npm downloadsLast4Weeks, downloadsSame4WeeksYearAgo, and medianDownloadsRatio: 230.4 million versus 24.2 million installs in the matching four-week windows.
- dependents, github stars, and peers: 701 indexed repos and 79 packages, with 13.2k stars. The two React peers index 41.7k and 97.4k repos.
- github.com/shadcn-ui/ui/blob/main/apps/v4/registry.json: The shadcn/ui Sonner registry entry declares the npm package as a dependency.
Vouched for7.6
Who stands behind it being good?
Claude Opus 5.5: 7.0, likely 5.5 to 8.0
It was shadcn/ui's recommended toast for years, and design systems such as Supabase's build on it. Several independent 2026 comparisons recommend it for new apps. There is no survey data and no visible Hacker News or Bluesky discussion, and shadcn/ui now points its Base UI users to another component.
- supabase.com/design-system/docs/components/sonner: Supabase's design system uses Sonner
- blog.logrocket.com/react-toast-libraries-compared-2026: Independent test and recommendation
- ui.shadcn.com/docs/components/radix/toast: Old shadcn Toast deprecated in favour of Sonner
- hackerNews, bluesky: No matched stories or posts
GPT-6.2 Sol: 8.1, likely 6.9 to 9.0
Supabase Studio and Dub list Sonner as an application dependency, and shadcn/ui recommends it for users of its deprecated Radix toast. An outside comparison measured a compressed size close to React-Toastify while documenting differences in features. The adoption evidence is current, while Sonner-specific satisfaction and retention remain unmeasured in the survey evidence.
- github.com/supabase/supabase/blob/master/apps/studio/package.json: Supabase Studio declares Sonner v2.0.8 or a compatible version.
- github.com/dubinc/dub.link/blob/main/apps/web/package.json: Dub's web application declares Sonner as a direct dependency.
- ui.shadcn.com/docs/components/radix/toast: shadcn/ui directs users of its deprecated Radix toast to Sonner.
- wingo-ui.com/blog/sonner-alternative-react-toast: An outside author measured bundle sizes and compared toast behavior.
Safe8.0
How safe is it to depend on?
Claude Opus 5.5: 8.0, likely 6.5 to 9.0
It has no dependencies, no known advisories and an MIT licence, so its attack surface is small. There is no OpenSSF Scorecard, and one maintainer appears to control publishing, which widens the range.
- advisories total: 0 advisories
- npm dependencies: 0 runtime dependencies
- scorecard: No Scorecard data
- npm license: MIT
GPT-6.2 Sol: 7.9, likely 6.5 to 9.1
The MIT license, zero added runtime dependencies, and zero listed OSV advisories support a high score. GitHub Actions shows browser tests, and GitHub lists one account behind the latest release as well as an absent security policy. With one listed npm maintainer, no Scorecard report, and unverified npm publishing provenance, release safeguards carry the most uncertainty.
- npm license and dependencies, advisories, and scorecard: MIT, zero runtime dependencies, zero OSV advisories, and no collected Scorecard.
- github.com/emilkowalski/sonner/security: GitHub detects no security policy and lists no published advisories.
- github.com/emilkowalski/sonner/actions: The public Actions history shows Playwright tests.
- github.com/emilkowalski/sonner/releases/tag/v2.0.8: The latest GitHub release is attributed to the project owner.
- socket.dev/npm/package/sonner: The package index lists one npm maintainer.
Good
- Good-looking stacked toasts out of the box, with a promise API, rich colours, action buttons and swipe to dismiss.
- No runtime dependencies, TypeScript types included, and safe in server-rendered Next.js apps.
- You can call toast() from anywhere without hooks, and AI coding agents write correct Sonner code because it is so common.
- By far the most-downloaded toast package in the category, and still growing faster than the median.
Bad
- Upkeep has slowed: 5 commits and 1 release in the last year, with 46 open pull requests.
- Mostly one maintainer, with no visible team or funding behind the work.
- Its built-in styling is harder to restyle fully than headless react-hot-toast, and its bundle is larger.
- shadcn/ui's default Base UI setup now ships its own Toast, so a main source of new users may shrink.
The numbers
- npm downloads, 4 weeks
- 230M ×9.5 in a year
- GitHub stars
- 13k
- Commits, 12 months
- 5
- npm version
- 2.0.8 Aug 2026
- Versions, 12 months
- 1
- Advisories, 24 months
- 0 of 0 ever
- OpenSSF Scorecard
- None
- Licence
- MIT
Read on 21 November 2026 from GitHub (emilkowalski/sonner), npm (sonner), OSV and the OpenSSF Scorecard.
Toasts and alerts
- 7.7Sonner
- 7.2React-Toastify
- 6.7react-hot-toast
- 6.6SweetAlert2
- 6.2Vue Sonner
- 4.6notistack
- 4.5Toastify JS
- 4.0Notyf