Device detection is a technique for identifying devices accessing online content. Knowledge of visiting devices is an essential asset for all businesses who want to maximize revenues from their websites and online services. It powers various aspects of web optimization, user experience, targeted advertising and device-aware web analytics tools.
Based on entries in the device database, a solution such as DeviceAtlas can report on the characteristics of visiting devices with an API, and this can be used for any purpose which requires device awareness. Read on to better understand how it works, what it’s used for, and how it’s deployed.
How device detection works
Device detection works by analysing User-Agent (UA) strings, and, in some cases, other HTTP headers. The detection mechanism searches for patterns within the User-Agent to match with an device entry in the device database in real time. High speed API calls can return the appropriate values for any device characteristic stored in the database.
For example, the API can be used to return the device’s operating system. This information can be used for any purpose where knowledge of the OS is needed, such as to optimize website content, or to serve targeted ads.
Why device detection is not easy to get right
The HTTP standard defines User-Agent strings as the default way to provide information about the device sending a request to the web server. However, the standard isn’t strict in terms of how User-Agent strings should be created which means that browser makers are free to use any keyword in the User-Agent or even create nonsensical UAs. The UA is sometimes used to represent a device as a different device from the one it actually is, which is known as “device masquerading”. A good solution must be sophisticated enough to be aware of any masquerading attempts in the UA string.
Test user-agent strings with a simple tool
Each device and browser combination comes with a unique User-Agent string, and there are many, many possible UA strings for each device. We created the User-Agent Tester tool. You can use it simply by copying and pasting any User-Agent string which is then looked up in our massive device database to return its detailed characteristics.
Here's an example User-Agent string which you can use to see how the tool works:
Mozilla/5.0 (Linux; Android 5.1.1; SAMSUNG SM-G925F Build/LMY47X) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/3.2 Chrome/38.0.2125.102 Mobile Safari/537.36
You can also use the User-Agent Tester with your own User-Agent strings or check out our list of example User-Agent strings published on the DeviceAtlas blog. Access the tool by clicking the link below (you need a free DeviceAtlas registration to use it).
What device detection is used for
Adaptive web design
Adaptive Web Design (AWD) is a technique in which different HTML is sent to different buckets of users according to their device type and capabilities. Each version of the website is highly optimized in terms of page weight, UX, and user context, to maximize engagement and sales. More
Optimizing web performance
In today’s world, users access websites on many device types, from phones, to tablets, to laptops, wearables to connected TVs. With a quality device detection solution like DeviceAtlas, you can ensure that your website is blazingly fast and lightweight regardless of the type of device and connectivity level. More
DeviceAtlas can be used for granular ad targeting based on detailed device characteristics. Targeting can include device types, operating systems, device vendors, screen sizes, mobile browsers, etc. This helps you build better-performing ad campaigns by making sure that they reach the right users at the right time. More
Detecting all characteristics of devices accessing websites is essential for web analytics platforms. DeviceAtlas powers many device analytics use cases, providing a detailed breakdown of web traffic according to device type, operating system, web browser, screen sizes, and much more, to drive data-driven business decisions. More
How it’s deployed
DeviceAtlas can be deployed as a cloud-based service or a locally installed solution. The mechanism for creating API calls and looking up devices in the database is similar for both options. The main difference is where the device data is stored. In the cloud-based version, DeviceAtlas servers return device information via the cloud. In the locally-installed version, the device data and API are deployed on the client’s own server and accessed locally from a highly optimized device data file that gets automatically updated on a daily basis.
If you need to integrate DeviceAtlas into your service to offer its capabilities to your clients, try our locally-installed solution. This option is typically used by ad servers, marketing platforms, web analytics solutions, etc.,
Myth 1: Device detection makes your site slower than RWD site
A device lookup can take as little as a few millionths of a second so there is no impact on the time a page takes to load. Top-performing device detection solutions are capable of making millions of detections every second and therefore it’s hard to imagine that a well-built adaptive site would be slower than a responsive site.
Myth 2: Adaptive design is the old-fashioned way to go, RWD is the way things are done today
We analyzed how some of the most visited websites are addressing mobile users today. All major online brands favour Adaptive Web Design using a knowledge of the device to allow them to provide mobile visitors with an optimized UX and high performance on any device or connection.
Myth 3: Google will penalize you for serving different content to mobile users
The idea that simply using RWD on your website will ‘automagically’ improve your search rankings more than AWD is nonsense. Responsive is not a remedy for all mobile SEO ills and you definitely won’t get penalized for not going responsive. Google lists adaptive design (as dynamic serving or separate URLs) as one of the methods for building mobile optimized content.
Myth 4: You can only choose between responsive and adaptive
Responsive and adaptive are not mutually exclusive options. Some websites apply a hybrid approach taking the best of both worlds called REsponsive web design with Server-Side components (RESS). You can use RESS to optimize some selected parts of an RWD site that may degrade the experience on mobile devices. Learn more: Lightening Your Responsive Website Design With RESS.
How to choose the right device detection provider
There is a number of factors to consider before selecting a device detection solution. Most importantly, you need to make sure that the solution doesn’t create a bottleneck, impeding performance of your online services, or report inaccurately, such as default results for unknowns. Learn more on how to pick the right provider by reading this guide (PDF).