Open In App

How to Use the Sensors Tool in Microsoft Edge

Last Updated : 23 Jul, 2025
Comments
Improve
Suggest changes
Like Article
Like
Report

The Sensors tool in the Microsoft Edge Developer Tools is an essential feature for developers who want to simulate and test how their website or web app interacts with device sensors. These sensors include things like geolocation, device orientation, and motion sensors. By using the Sensors tool, developers can test their sites in real-world scenarios, such as checking how a website behaves when a device is rotated or simulating different geographic locations. This tool is especially useful for building and testing mobile-first or location-based web applications.

What is the Sensors Tool in Microsoft Edge?

The Sensors Tool in Microsoft Edge is part of the Developer Tools suite that allows web developers to emulate physical sensors of devices for testing purposes. With this tool, you can simulate geolocation changes, device orientation, touch events, and more, directly from your desktop. This helps developers test how their websites or web applications respond to changes that occur on mobile devices without needing actual mobile devices.

This tool is especially useful when developing responsive websites and web applications that must adapt to different devices, screen sizes, and user behaviors, including orientation changes or geolocation shifts.

Types of Sensors

There are many sensors used in the device, but out of them, only some are usable or are allowed by the browsers for any usage. Some of the commonly used sensors in web technology are:

  • GPS (Global Positioning System): Most commonly and widely used sensors used for location tracking. Many websites and apps use this technology, from location tracking to gaming.
  • Motion and Orientation: Many devices are embedded with accelerometers and gyroscopes for detection of motions and tilt or orientation of the device, which can be used by apps or websites to add additional inputs using motion, change the UI, or add inputs depending on the tilt or orientation of the device.
  • Light: Light sensors are basically used to change the screen brightness and can also be used to measure light. The websites can use this data to change the color contrast of the colors used on the site for better viewing.
  • Biometric: Any sensors that are used to identify an individual are biometric sensors, such as fingerprint, face, eye, etc. The websites can use it for additional security measures.
  • Touch: Touch sensors basically allow the user to use the device by just using their fingers. For multiple functionality, the behavior and the number of touches are computed, such as hold, two-finger zoom, and two-finger slide down. The websites can be designed to add additional inputs with the means of touch, as it is a better and faster method to provide input by the users.

How to Access the Sensors Tool in Microsoft Edge

Before we dive into the features of the Sensors Tool, let's first go over how to access it in Microsoft Edge.

Step 1: Open Microsoft Edge DevTools

  • Launch Microsoft Edge on your device.
  • Open DevTools by pressing Ctrl + Shift + I (on Windows) or Cmd + Option + I (on macOS).
  • Alternatively, right-click on a webpage and select Inspect to open DevTools.

Step 2: Access the Sensors Tool

  • In the DevTools panel, click the three-dot menu icon (Customize and control DevTools) in the top-right corner.
  • Select More tools > Sensors.

Once you open the Sensors panel, you can begin using the various simulation options available.

run-command
Opening Sensors Tool using Run Command

Key Features of the Sensors Tool in Edge

The Sensors Tool in Microsoft Edge lets you emulate a variety of physical device sensors, which can be crucial for testing specific web application features.

1. Emulate Geolocation (GPS)

With the geolocation override feature, you can simulate the geographical location of a device. This is particularly useful for testing location-based services or content that changes based on where the user is located.

How to Use Geolocation Override:

  • In the Sensors panel, you'll find a Geolocation section.
  • Select a preset location from the dropdown, or enter custom latitude and longitude coordinates to simulate any location globally.
  • You can also test how your web application behaves when no location is available by selecting Location unavailable.

This feature is ideal for testing apps that provide maps, location-based services, or tailored content based on the user's location.

options-in-geolocation
Drop-down List for Locations
  • Latitude: Used to set custom value of latitude.
  • Longitude: Used to set custom value of longitude.
  • Timezone ID: Used to set any time zone using a Timezone ID.
  • Locale: Use to change the locale of the site.
location-option
Various Location Options

2. Simulate Device Orientation

The Device Orientation tool allows you to test how your website responds to changes in the device's orientation, such as rotating a mobile device from portrait to landscape mode.

How to Use Device Orientation:

  • Within the Sensors panel, find the Device Orientation section.
  • Here, you can adjust the alpha, beta, and gamma values, which correspond to the rotation of the device in 3D space (around the z, x, and y axes).
  • Use these settings to simulate tilting, rotating, and turning the device to see how your website responds.
orientaiton-dropdown
Drop-down list for Orientation

Testing this feature is critical for web applications that support mobile devices or responsive design elements.

orientaiton
Custom Orientation

3. Simulate Touch Events

If your website has interactive touch-based features, the Sensors Tool allows you to simulate touch events, which can be crucial for testing mobile-specific interactions.

How to Use Touch Event Simulation:

  • In the Sensors panel, toggle the Emulate touch events checkbox to enable touch simulations.
  • Once enabled, you can interact with your page as if you were on a touch device, testing swipe gestures, taps, and other touch-based interactions.

This feature is perfect for web developers working on mobile-first or touch-enabled web apps.

Touch
Touch Options

4. Changing User and Screen State using Sensors Tool:

We can change the user state to active or idle and the screen state to locked or unlocked using the Sensors tool. This helps to check if the site makes changes depending on the state of the screen or the user.

The Emulate Idle Detector State provides a drop-down list of various options:

  • No idle emulation
  • User active, screen unlocked
  • User active, screen locked
  • User idle, screen unlocked
  • User idle, screen locked
idle
Emulate Idle detector State

5. Emulate Device Posture for Foldable and Dual-Screen Devices

With the increasing popularity of foldable and dual-screen devices like the Microsoft Surface Duo and Samsung Galaxy Z Fold, it's essential to test how your app behaves on these unique form factors.

How to Use Foldable and Dual-Screen Device Simulation:

  • In the Sensors panel, select Device Posture from the options.
  • Choose between Continuous (flat) or Folded (angled) postures to emulate how your app would appear and function on a foldable or dual-screen device.
  • You can also simulate dual-screen devices by selecting a device like Surface Duo in the device list and toggling between dual and single-screen modes.

This is particularly useful for developers building apps that support Windows 11's dual-screen capabilities or any foldable device features.

Best Use Cases for the Sensors Tool in Microsoft Edge

1. Testing Location-Based Features

For applications that rely on the user’s location, such as mapping apps or location-specific content, the Sensors Tool is a great way to simulate different geographic locations without needing physical devices.

2. Device Orientation and Mobile-Responsive Testing

For websites that adapt based on device orientation (portrait vs. landscape), the orientation simulator allows you to test how the website layout changes with different screen rotations.

3. Touch Event Simulation

If your application supports touch-based interactions, you can emulate touch gestures like swipes and taps using the Sensors Tool. This helps test touch-based features on a desktop browser, even if the device is not touch-enabled.

4. Testing for Foldable and Dual-Screen Devices

With foldable and dual-screen devices becoming more popular, the device posture simulation is essential for ensuring your website or app is optimized for these new form factors. Testing on a single screen and switching to dual-screen mode allows you to ensure seamless user experiences across different devices.

Conclusion:

The Sensors tool in Microsoft Edge provides a powerful way for developers to test and optimize their websites for mobile and location-based functionalities. By using this tool, developers can simulate various device sensor data like motion, orientation, and geolocation, ensuring their applications work smoothly across different devices and environments. It’s an invaluable tool for any developer looking to build responsive and location-aware web applications.


Next Article

Similar Reads