51Deg Logo
Meet the new

51Degrees UAParser

A lightweight JavaScript library wrapping 51Degrees Device Detection cloud service. The library provides comprehensive device data based on User-Agent Client Hints and/or the User-Agent. This package can be used either in a browser (client-side) or Node.js environment (server-side).

Client-side supports both detection of the current client and detection from an arbitrary header map, while server-side supports detection from a header map only.

Free download

User-Agent Data Playground

This is what we get from your User-Agent data:
Detected device data:
Try more examples Pick another HTTP header to test:
Specify another set of User-Agent and/or User-Agent Client Hint headers:

Less is More

Extensive device data

51Degrees UAParser provides access to the 51Degrees Cloud service, which can identify over 200 different device properties, such as platform, browser, engine, CPU, and vendors.

Small library footprint

The 51Degrees UAParser library footprint is a tiny 13KB, which is smaller than many other available User-Agent parsers available.

Open source with a freemium model

We recognize the value of open source – that’s why the 51Degrees UAParser library is freely available with a limited set of data properties. If you require extra data points or more requests per month, we offer different pricing plans to suit your needs.

Client-side and server-side

Whether it's a client-side webpage running in a browser or a server-side Node.js app, simply type:

$ npm i @51degrees/ua-parser-js --save

Detect Apple devices

Unlike some other User-Agent parsers, 51Degrees UAParser can reliably detect Apple device data. See what results you can expect from our Apple device detection.

A human touch

The device data is maintained and updated by a professional data analyst team on a regular basis.

Getting started

To get started with 51Degrees UAParser, please follow the instructions within the GitHub README file.

Creating a Resource Key is a requirement in order for 51Degrees UAParser to work; follow this link to configure a Resource Key. Please note, following this link will prepopulate your Key with the recommended minimum properties. Other properties are available, but may require the purchase of a 51Degrees pricing plan.

You can also follow our Configurator guide to create a Key from scratch if needed. Note that if you require reliable detection of Apple devices, the Resource Key must contain the JavascriptHardwareProfile property.

For a live demo of the 51Degrees UAParser, check out our webinar.

The minimum recommended properties to include in your Resource Key are:
  • IsMobile
  • HardwareVendor, HardwareModel, HardwareName
  • PlatformVendor, PlatformName, PlatformVersion
  • LayoutEngine
  • BrowserVendor, BrowserName, BrowserVersion
  • JavascriptHardwareProfile
  • DeviceType
  • SetHeaderBrowserAccept-CH,
Try it for free

The question isn't "why should you?", it's "why on earth wouldn't you?".

Free download