Web APIs

Notifications API

Checking compatibility...

Display native system notifications from web applications. Learn to create, customize, and handle user interactions with push notifications.

Request Permission

Ask for permission to show notifications. This example demonstrates how to properly request notification access from users, which is required before any notifications can be displayed.

=
=
=
=
=
=

Output

Click Run to see output...

Basic Notification

Create a simple notification with title and message. This example shows how to display a standard notification with minimal setup once you have permission.

=
=
=
=
=
=

Output

Click Run to see output...

Advanced Notification

Create rich notifications with icons and interactive features. This example demonstrates how to build notifications with custom styling, actions, and event handling for user interactions.

=
=
=
=
=
=

Output

Click Run to see output...