page event records whenever a user views a page on your website or a screen in your mobile app. Both the web SDK and mobile SDK emit page events with channel set to "web" or "mobile" respectively.
On web, page properties are automatically collected from the browser. On mobile, the screen name is mapped to page-equivalent fields (page_title, page_path, page_url) so that web and mobile views are processed through the same analytics pipeline.
Fields
Apart from the common fields, thepage call accepts the following properties:
| Property | Type | Description |
|---|---|---|
url | String | Full URL of the page. |
path | String | Path component of the URL (without query string or hash). |
hash | String | Hash fragment of the URL (e.g., #section). |
query | String | Query string of the URL (without the leading ?). |
name | String | Name of the page or screen. |
category | String | Category of the page or screen. |
title | String | Title of the page. |
Properties
The following table shows which properties are automatically set by each SDK:| Property | Web SDK | Mobile SDK |
|---|---|---|
properties.url | window.location.href | Not set |
properties.path | window.location.pathname | Not set |
properties.hash | window.location.hash | Not set |
properties.query | window.location.search | Not set |
properties.name | Caller-provided | Screen name (required) |
properties.category | Caller-provided | Caller-provided |
context.page_url | window.location.href | app://{screenName} |
context.page_title | document.title | Screen name |
context.page_path | Not set (derived in backend) | Not set (derived in backend) |
context.referrer | document.referrer | From deep link (if set) |
context.user_agent | Browser user agent | Device user agent (if available) |
context.os_name | Not set | iOS or Android |
context.device_type | Not set | mobile or tablet |
context.app_name | Not set | From native config or options |
context.app_version | Not set | From native config or options |
channel | "web" | "mobile" |
Sample Payload (Web)
Sample Payload (Mobile)
Screen events from the mobile SDK are sent aspage events with channel: "mobile":