Skip to main content
@capgo/capacitor-rich-notifications Communication Open source

Rich Notifications Capacitor plugin

Local notifications with Android channels, progress layouts, action buttons, scheduling, and iOS interruption levels

Install

bun add @capgo/capacitor-rich-notifications bunx cap sync
npm, pnpm or yarn
  • npm install @capgo/capacitor-rich-notifications
  • pnpm add @capgo/capacitor-rich-notifications
  • yarn add @capgo/capacitor-rich-notifications

Guide

How to use Rich Notifications in Capacitor

Using @capgo/capacitor-rich-notifications

Local notifications with Android channels, progress layouts, action buttons, scheduling, and iOS interruption levels.

Install

bun add @capgo/capacitor-rich-notifications
bunx cap sync

What This Plugin Exposes

  • checkPermission - Check local notification permission status.
  • requestPermission - Request local notification permission.
  • createChannel - Create an Android notification channel.
  • createChannelGroup - Create an Android channel group.
  • deleteChannel - Delete an Android notification channel.
  • display - Display a local notification immediately.
  • schedule - Schedule a local notification for later.
  • cancel - Cancel one notification by id.
  • cancelAll - Cancel every notification managed by this plugin.
  • getDisplayed - List notifications shown in the shade or center.
  • getPending - List scheduled notifications not yet shown.
  • getInitialNotification - Return the notification that opened the app, if any.
  • setBadge - Set the app icon badge count on iOS.
  • registerActions - Register a reusable action category.
  • getPluginVersion - Returns the platform implementation version marker.
  • addListener - Listen for press and dismiss events.

Example Usage

requestPermission and display

import { RichNotifications } from '@capgo/capacitor-rich-notifications';

await RichNotifications.requestPermission();

await RichNotifications.createChannel({
  id: 'messages',
  name: 'Messages',
  importance: 'high',
});

await RichNotifications.display({
  title: 'Hello',
  body: 'Tap to open the app',
  channelId: 'messages',
});

schedule

import { RichNotifications } from '@capgo/capacitor-rich-notifications';

await RichNotifications.schedule({
  notification: {
    id: 'reminder-1',
    title: 'Reminder',
    body: 'Your appointment starts soon',
    channelId: 'messages',
  },
  trigger: { type: 'timestamp', timestamp: Date.now() + 60_000 },
});

Full Reference

FAQ

Rich Notifications plugin FAQ

How do I install the Rich Notifications plugin in a Capacitor app?

Run "bun add @capgo/capacitor-rich-notifications" (or "npm install @capgo/capacitor-rich-notifications"), then run "bunx cap sync" so the iOS and Android projects pick up the native code. Import it from "@capgo/capacitor-rich-notifications" in your app code.

Does @capgo/capacitor-rich-notifications work with React, Vue and Angular?

Yes. Rich Notifications is a Capacitor package, so it works with any web framework that runs inside Capacitor, including Ionic, React, Vue, Angular, Svelte and plain JavaScript.

Which Capacitor version does @capgo/capacitor-rich-notifications support?

Capgo plugins follow Capacitor's major version: use the plugin major version that matches your Capacitor major version (for example plugin v8 with Capacitor 8). The compatibility table in the GitHub README lists the maintained versions.

Is @capgo/capacitor-rich-notifications free and open source?

Yes. The source code is public on GitHub at https://github.com/Cap-go/capacitor-rich-notifications/ and the package is free to install from npm. Bug reports and pull requests are welcome.

Can I update code that uses Rich Notifications without an App Store review?

Installing or upgrading the plugin changes native code, so it needs a new store build. After that, JavaScript, HTML and CSS changes that call the plugin can ship instantly with Capgo live updates.

Ship Rich Notifications changes without waiting for app review

Once the plugin is in your store build, Capgo live updates push your JavaScript, HTML and CSS changes to users in minutes.

Start with Capgo