---
title: Automatically track native marks and measures
source: https://docs.newrelic.com/docs/browser/new-relic-browser/browser-pro-features/marks-and-measures
---

[Marks](https://developer.mozilla.org/en-US/docs/Web/API/Performance/mark) and [measures](https://developer.mozilla.org/en-US/docs/Web/API/Performance/measure) are standard browser APIs that help you observe and report on the performance of your webpages. These generic, native events allow you to measure the duration of any task or process in your application. With New Relic browser monitoring, you can now automatically track marks and measures and store them as `BrowserPerformance` events—giving you deeper visibility into your site's real-world performance.

## Why use marks and measures monitoring?

Automatic tracking of marks and measures with New Relic provides actionable insights into the performance of your web applications. By capturing these events, you can:

-   Pinpoint slow or problematic areas in your code.
-   Measure the impact of new features or deployments.
-   Compare performance across different user journeys.
-   Build custom dashboards and alerts based on real user data.

## Prerequisites [#prerequisites]

-   A **Pro** or **Pro + SPA** browser agent, version 1.272.0 or higher.

> #### ⚠️ IMPORTANT
>
> Automatic marks and measures detection is not available for the Lite browser agent.

## Enable automatic collection [#enable-collection]

Enhance your application's observability and debugging capabilities by following these simple setup instructions.

1.  Go to **[one.newrelic.com](https://one.newrelic.com) > All Capabilities > Browser**.
2.  Select your browser app.
3.  In the left-hand menu, click **Application settings**.
4.  Ensure the **Pro** or **Pro + SPA** browser agent is selected.
5.  To automatically collect marks, turn on **Capture marks**.
    To automatically collect measures, turn on **Capture measures**.
    To collect details from observed marks or measures as custom attributes, turn on **Add details**.

![screenshot of the marks and measures settings panel in browser application settings](<https://docs.newrelic.com/images/M_and_M settings.png> "Marks and measures settings")

## Disable marks and measures collection [#disable-marks-and-measures]

To disable marks and/or measures for an existing browser app:

1.  Go to **[one.newrelic.com](https://one.newrelic.com) > All Capabilities > Browser**.
2.  Select your browser app.
3.  In the left-hand menu, click **Application settings**.
4.  To disable marks, turn off **Capture marks**.
    To disable measures, turn off **Capture measures**.

## Data consumption

`BrowserPerformance` events follow the same consumption pricing as your other browser bytes. The amount of bytes produced depends on the count and attributes of the data.

Once enabled, the agent will automatically capture marks and measures as they occur in your application.

## Find your data in New Relic [#find-data]

Marks and measures data are stored as `BrowserPerformance` events in New Relic, denoted as either `mark` or `measure` under the `entryType` field. See the [data dictionary](https://docs.newrelic.com/attribute-dictionary/?event=BrowserPerformance) for more information on the fields available for use with `BrowserPerformance` events. For a quick and useful dashboard, see this [quickstart](https://newrelic.com/instant-observability/browser-marks-and-measures), otherwise you can query and visualize this data to gain insights into your application's performance.

**Find the slowest measures by average duration**

```nrql
FROM BrowserPerformance 
SELECT average(entryDuration) 
WHERE entryType = 'measure' 
FACET entryName 
LIMIT 10 
ORDER BY average(entryDuration) DESC
```

**Count the number of marks and measures per page**

```nrql
FROM BrowserPerformance 
SELECT count(*) 
WHERE entryType IN ('mark', 'measure') 
FACET pageUrl
```

**See average measure duration by browser**

```nrql
FROM BrowserPerformance 
SELECT average(entryDuration) 
WHERE entryType = 'measure' 
FACET userAgentName
```

**Track measure durations by country**

```nrql
FROM BrowserPerformance 
SELECT average(entryDuration) 
WHERE entryType = 'measure' 
FACET countryCode
```

**Find all unique measure names recorded in the last 24 hours**

```nrql
FROM BrowserPerformance 
SELECT uniqueCount(entryName) 
WHERE entryType = 'measure' 
SINCE 24 hours ago
```

**Compare measure durations for desktop vs. mobile**

```nrql
FROM BrowserPerformance 
SELECT average(entryDuration) 
WHERE entryType = 'measure' 
FACET deviceType
```

**List all measures for a specific session**

```nrql
FROM BrowserPerformance 
SELECT * 
WHERE entryType = 'measure' 
AND session = 'abcdefghijklmnop'
```

Use these queries or create your own to build custom dashboards, set up alerts, and monitor the real-world performance of your web applications with precision.

> #### 💡 TIP
>
> Need help or want to learn more about using marks and measures in New Relic? Visit our [documentation](https://docs.newrelic.com/) or reach out to [support.newrelic.com](https://support.newrelic.com).
