Skip to Content
Platform.Ontology

Screen orientation

Reads portrait or landscape and angle.

Gets silentlyScreen and windowsScreenWeb browsersWhen the page loadsWhile you use it

In one line

Can check whether your screen is portrait or landscape and its angle

Reads portrait or landscape and angle.

Shows how the phone or tablet is held and whether a laptop screen is rotated.

What it can and can't do

What the user does: Nothing. It happens when the page loads or you rotate the device.

It can

  • Check portrait or landscape
  • Check the rotation angle
  • Notice when you rotate the device

It cannot

  • See the device's tilt or movement
  • Rotate your screen for you
  • See how you hold the device when rotation is locked

Browser support

BrowserStatusFirst versionReleasedNote
ChromeSupported382014-10-07None
EdgeSupported792020-01-15None
FirefoxSupported432015-12-15None
SafariSupported16.42023-03-27None
Safari on iPhoneSupported16.42023-03-27None
Chrome on AndroidSupported392014-11-12None
Samsung InternetSupported4.02016-03-11None

How a site asks for it

APIscreen.orientation.type, angle
Browser compat keysapi.Screen.orientation
How access is grantednone
What the user seesNone (no browser prompt)
Needs a secure context (HTTPS)No
Needs a user gestureNo
How long it lastsNot listed
How to take it backNot listed
Inside an iframeNot listed

Typical flow

  1. Script reads the value
  2. Value joins the fingerprint payload

Data you get

What comes back: Screen orientation
Shape: enum
How often: on rotate

FieldTypeUnitRangePrecision
typeenumNoneportrait-primary and othersNot listed
angleintegerdegrees0, 90, 180, 270Not listed

Technical limits

  • Not a motion sensor

The story

What it is

Reads whether the screen is portrait or landscape, and the angle.

For you

You turn your phone and the page rearranges. The angle can be 0, 90 or 180 degrees. You never see the reading.

For makers

Makers use it to reshape layouts. It is also a quick way to tell a real phone from a desktop browser faking one, because real phones rotate and desktops do not.

Where you see it

TypeExampleApps
gamesA browser game switches from a tall menu to a wide play field when you turn your phone.None named
videoA video page goes full screen when you rotate to landscape.YouTube
mapsA web map moves its search bar and info card when you rotate.Google Maps
shoppingA store shows more of each photo in landscape on tablets.None named
securityA fraud check sees motion from a phone with an angle that never changes, which can mean an emulator.None named
educationA reading app switches to a two page spread in landscape on tablets.None named

Risks

  • Mild fingerprint clue
  • Hints at device type

What the platform says

Good uses and abuse

Legitimate uses

  • Adapt layout

Known abuse

  • Fingerprint input

Scores

ScoreValueMeaning
Sensitivity2 of 5How revealing the data is
Utility3 of 5How useful it is to honest apps
Friction0 of 5How much the user has to do
Fingerprint bits2Rough identifying entropy, when known

A real example: LinkedIn

Collector key(s): screenOrientation.

Sources

How well checked: Based on official documentation.

On this page