Web APIs

Beacon API

Checking compatibility...

Send analytics data using Beacon API. Learn how to send data before the page is unloaded.

Basic Analytics

This example shows how to send user activity data to your server without blocking the page or slowing down the user experience.

=
=
=
=
=
=

Output

Click Run to see output...

Page Unload Tracking

This example captures when a user is leaving your page and sends final analytics data before they go, ensuring you don't lose important information.

=
=
=
=
=
=

Output

Click Run to see output...