Runs in your browser ยท nothing uploaded
  1. Home
  2. Guides
  3. How to Check Your Device Type
Device

How to Check Your Device Type

Learn how to accurately determine if you are using a phone, tablet, or desktop by combining touch support, viewport size, and user agent data.

By DeviceInfo Editorial Team October 16, 2026 5 min read

Illustration for the guide: How to Check Your Device Type

Short answer

To check your device type, you must synthesize multiple signals because no single API definitively labels a device as "phone" or "desktop." Combine touch capability, viewport dimensions, and user agent strings to estimate the category: a small viewport with active touch support indicates a mobile phone, while a large screen with fine pointer control indicates a desktop.

What the check does

Browser-based device detection does not scan your physical hardware. Instead, it reads the metadata that your browser voluntarily exposes. The process involves checking three primary areas: whether the screen supports multi-touch input, the current width of the visible viewport, and the User-Agent string that identifies your browser and operating system. Modern browsers also provide Client Hints, which are specific headers that may contain platform details. By cross-referencing these values, a diagnostic tool can estimate your device category with reasonable accuracy.

How to read the result

Interpreting these signals requires pattern matching rather than relying on a single field. If the results show "touch: true" and a viewport width under 800 pixels, you are almost certainly on a smartphone. Conversely, "touch: false" with a large viewport and a "fine" pointer type indicates a traditional desktop computer. However, exceptions exist. Tablets in "desktop mode" may report as PCs despite having touchscreens, and laptops with touch displays will report touch support but are identified as desktops due to their larger screen size. Always look at the combination of touch, pointer type, and screen size to get an accurate verdict.

What the values mean

The table below breaks down the key signals used to determine device type. Modern browsers may withhold some data for privacy, resulting in blank fields rather than incorrect ones.

SignalWhat it measuresTypical Mobile ValueTypical Desktop Value
Touch SupportMulti-touch input capabilityTrueFalse (or True on 2-in-1s)
Viewport WidthVisible area width in pixelsLess than 800pxGreater than 1000px
Pointer TypePrimary input method'coarse' (finger)'fine' (mouse/trackpad)
User-AgentBrowser and OS identificationContains 'Mobile' or 'Android'Contains 'Windows' or 'Macintosh'

A "Mobile" verdict usually means the touch signal is true and the pointer is coarse. A "Desktop" verdict suggests fine pointer control and a large viewport. Zoom level can affect this; zooming out makes a phone's viewport appear wider, which can confuse simple width-based checks, so always test at default zoom.

Common questions

  • Why does my tablet say it is a desktop? Many tablets have a "desktop mode" toggle that forces the User-Agent to mimic a PC.
  • Can I trust the User-Agent string? No. It is easily spoofed and browsers are phasing it out in favor of subtle Client Hints.
  • What is a foldable device type? It depends on the screen state. When folded, it looks like a phone; when open, it may look like a tablet.
  • Does zoom level affect results? Yes. Zooming out increases the viewport width, potentially confusing width-based checks.
  • Why are some fields blank? Browsers hide hardware identifiers to prevent tracking. Blank fields mean "not revealed," not "error."

Try it live

The most reliable way to see these signals in action is to run a live test. This tool collects your current touch support, viewport size, and user agent data, then interprets them together to give you a clear verdict. Use our Device Type Checker to view your specific signals immediately. For more context on how this data is generated, see our guide on how websites detect your device.

Limitations

Modern browsers prioritize user privacy, which means they withhold specific hardware details. You cannot definitively identify the exact device model, and certain fields may be empty by design. Client Hints are subject to privacy limits, and User-Agent strings are becoming less detailed over time. Always treat device type detection as a probability based on available signals rather than an absolute fact.

Frequently asked questions

Is there a way to detect the exact model of my phone?

No. Browsers actively prevent web pages from identifying specific hardware models like "Pixel 8" or "iPhone 14" to protect privacy. You can only determine the general operating system and screen dimensions.

What happens if I use a phone browser in private mode?

Private mode restricts storage and fingerprinting data, but core signals like touch support and viewport size remain available. Device type detection usually works the same, though advanced identification features may be blocked.

Can a website know if I am using a mouse and a touchscreen?

Yes. Modern laptops and Android tablets often support both. The browser will report "touch: true" even if you are currently using a mouse. This is why User-Agent and platform hints are necessary for a complete picture.

Why do some older browsers show different results?

Older browsers lack support for modern standards like Client Hints or detailed pointer capabilities. They rely solely on User-Agent strings, which are less accurate. Check your browser version to ensure you are using the most reliable signals available.

Your device, your values

See this on your own browser right now

Keep reading