Real User Monitoring (RUM) collects performance data directly from your website’s actual visitors. It captures how your site performs in real-world conditions, measuring how your end users experience your site across different devices, browsers, and networks.
Prerequisites
To use RUM, you need permission to edit your website’s code. Uptrends provides a script that you insert into your site. Once the script is added, RUM begins collecting data.
Set up Uptrends RUM
To set up Uptrends RUM:
- Add a RUM website.
- Implement script on your website.
- Track your website performance using RUM dashboards.
Add a RUM website
- Go to .
- Enter a name for your RUM website.
- Enter the URL to monitor.
- If you use a single-page application (SPA), enable Use Single Page Application Tracking.
- To track URL fragments (for example,
#fragmentin/page#fragment), enable Include URL fragment. - Click Save to generate the RUM script.
- Go to Implementation and copy the script.
The RUM script is a lightweight JavaScript snippet that you insert on your website’s pages to measure your users' experience. The script is designed to avoid interfering with other scripts on your website, ensuring that your end users will not notice any impact. For more details, see Impact of the RUM script on your website.
Implement the script on your website
To add the script to your website:
- Paste the script into the
<head>section of each page you want to monitor. Placing it in the<head>section ensures that the script loads as early as possible, capturing all relevant performance timing data.
- If your site uses a Content Security Policy (CSP), ensure that the Uptrends RUM domain (
https://hit.uptrendsdata.com) is added and correctly configured in your Content Security Policy.
-
Verify that the Uptrends RUM script is working properly:
a. Inspect your website’s source code and confirm that the Uptrends RUM script is present.
b. Open the Developer Tools > Network tab in your browser and verify that Uptrends RUM resources load without errors.
-
Deploy your website with the script included.
Once visitors access the updated pages, RUM will collect data and display it in your RUM dashboard in real time.
Site ID
Each RUM script is designed for a single website. It includes a unique sid (site ID) that identifies the corresponding RUM website in your account. Uptrends records page views only from the domain that you specify.
Example
If your site is www.your-domain.com, the script works on both www.your-domain.com and your-domain.com. However, if you use the script on test.your-domain.com or any other domain, Uptrends will not record page views. Each website or domain requires its own RUM website and script.
In this example, RUM only works in your production environment. If you have separate development and test environments running locally or under a different domain, RUM will not register page views for those sites.
License
The Uptrends RUM script and its components are provided under a Berkeley Software Distribution (BSD) license. You can find the full BSD license text. For information about how Uptrends protects user privacy, see RUM and user privacy.