Configure custom browser tag
Configure custom browser names (tags) in Percy on Automate to group and compare snapshots across browsers, OS versions, and devices.
Custom browser tags identify a platform capability used for Percy on Automate snapshots with a single, consistent tag. When you apply the same tag to different platform capabilities, Percy compares snapshots captured from those capabilities using the same tag.
Use custom browser tags as a configuration-level setting to control how Percy compares visual tests across different platforms using the same tag name.
Requirements
Ensure you have the following before configuring custom browser tags:
- Percy CLI version: 1.31.6 or later
- Platform: Percy on Automate (POA)
When you use the BrowserStack SDK, create a .percy.yml file explicitly to use custom browser tags.
How custom browser tags work
Percy uses the custom browser name you define as the primary identifier for a platform capability. When two different capabilities share the same custom browser tag, Percy uses that identifier to compare snapshots across different OS, OS versions, browser names, or browser versions.
This approach helps you maintain stable baselines while continuing to test across updated platforms and environments.
Configure custom browser tags
You can configure custom browser tags in your .percy.yml file using the platforms array under the percy section.
Each platform entry supports a custom browser name that Percy uses for snapshot grouping and comparison.
Percy evaluates platform configurations in the order they appear in your .percy.yml file. If multiple entries match a snapshot, the first matching entry is used to apply the custom browser tag.
Supported configuration options
The following properties are available when defining platforms in your .percy.yml configuration file:
| Property | Type | Required | Description |
|---|---|---|---|
| os | string | No | Operating system name (e.g., “Windows”, “macOS”, “iOS”, “Android”) |
| osVersion | string/number | No | Operating system version (e.g., “11”, “Ventura”, “15”) |
| browserName | string | No | Browser name (e.g., “Chrome”, “Safari”, “Firefox”, “Edge”) |
| browserVersion | string/number | No | Browser version (e.g., “118”, “latest”, “120.0”) |
| deviceName | string | No | Device name for mobile testing (e.g., “iPhone 13”, “Samsung Galaxy S21”) |
| percyBrowserCustomName | string | Yes | The custom name/tag to use for this platform configuration |
What you can do with custom browser tags?
By keeping the same custom browser tag across builds, you can compare snapshots even when platform capabilities change.
Compare browser versions
Compare multiple versions of the same browser, such as Chrome 137 and Chrome latest, using a single custom browser name.
| Change between builds | Base build | Head build | Comparison result |
|---|---|---|---|
| Operating system | Windows | macOS | Compare snapshots across operating systems |
| OS version | Windows 10 | Windows 11 | Compare snapshots across OS versions |
| Device | iPhone 11 Pro Max | iPhone 13 Pro Max | Compare snapshots across devices |
| Browser | Chrome | Edge | Compare snapshots across browsers |
| Browser version | Chrome 118 | Chrome latest | Compare snapshots across browser versions |
In all scenarios, both builds must use the same custom browser tag for Percy to compare snapshots.
Best practices
- Use
browserVersion: "latest"to keep baselines stable across browser updates. - Define one platform configuration per browser and OS combination unless you need version-specific comparisons.
- Keep custom browser tag names consistent and descriptive.
- Validate your
.percy.ymlconfiguration in a test environment before using it broadly.
Things to keep in mind
- Percy applies a custom browser tag only when the platform configuration matches the running test environment.
- For iOS and Android platforms, you must specify a
deviceNameto apply a custom browser tag.
We're sorry to hear that. Please share your feedback so we can do better
Contact our Support team for immediate help while we work on improving our docs.
We're continuously improving our docs. We'd love to know what you liked
We're sorry to hear that. Please share your feedback so we can do better
Contact our Support team for immediate help while we work on improving our docs.
We're continuously improving our docs. We'd love to know what you liked
Thank you for your valuable feedback!