← Topic directory

Device & Hardware

Hardware access from the browser: WebUSB, Web Bluetooth, WebSerial, WebHID, WebNFC, and sensor APIs.

36 features tagged with this topic.

Cross-browser consensus

Features by stage

Enabled by default (23)

Direct Sockets API

Allows Isolated Web Apps to establish direct transmission control protocol (TCP) and user datagram protocol (UDP) communications with network devices and systems as well as listen to and accept incoming connections.

Also tagged: Progressive Web Apps

Gamepad API Trigger-Rumble Extension

Extend the GamepadHapticActuator interface to expose the trigger-rumble capability in the Web for compatible gamepads. This extension will allow web applications that take advantage of the Gamepad API to also vibrate the triggers of gamepad devices that come equipped with this functionality.

Also tagged: Progressive Web Apps

Permissions Policy for Web Bluetooth API

Integrates the Web Bluetooth API with Permissions Policy, which should be identified by the "bluetooth" token. The Web Bluetooth API allows webpages to communicate with devices over Bluetooth. However, this API is not allowed to be used from cross-origin iframes. This integration enables this scenario while providing protection against unwanted access to Bluetooth capabilities, which requires the top-level document to explicitly allow a cross-origin iframe to use the API's methods.

Also tagged: Security & Authentication

SerialPort BYOB reader support

Updates the underlying data source for the ReadableStream provided by a SerialPort to be a readable byte stream. This change is backwards-compatible with existing code that calls port.readable.getReader() with no parameters. Developers can detect support for BYOB readers by calling getReader({ mode: 'byob' }) as older implementations will throw a TypeError when the new parameter is passed. BYOB (or, "bring your own buffer") readers allow the developer to specify the buffer into which data is read instead of the stream allocating a new buffer for each chunk. In addition to potentially reducing memory pressure this allows the developer to control how much data is received as the stream cannot return more than there is space for in the provided buffer. The ability to read a particular amount of data from a port makes this API more familiar to developers used to programming against the Windows and POSIX APIs for serial devices, which operate on this same "bring your own buffer" principle.

Support for WebHID

The [WebHID API](https://developer.chrome.com/docs/extensions/how-to/web-platform/webhid) enables web applications to interact with Human Interface Devices (HIDs) over USB and Bluetooth beyond standard system input mappings (such as mice, keyboards, touchscreens, and standard gamepads). Web applications can request user permission to connect to HID devices, send and receive input, output, and feature reports, and inspect report descriptors. WebHID shipped on [desktop platforms](https://developer.chrome.com/docs/capabilities/web-apis/hid-examples) (Windows, macOS, Linux, and ChromeOS) in Chrome 89. Chrome 158 brings the existing WebHID API to Chrome on Android (relying on new OS support in Android 17 / API level 37 and later) with no changes to the web-exposed API surface. Popular uses today include customizing mechanical keyboards, keypads, and gaming mice, calibrating gamepads, and integrating hardware headset call controls in call centers. WebView is not supported, as it does not have a device chooser UI or permissions UX controls. This feature can be controlled using the following enterprise policies: * [DefaultWebHidGuardSetting](https://chromeenterprise.google/policies/#DefaultWebHidGuardSetting) * [WebHidAllowAllDevicesForUrls](https://chromeenterprise.google/policies/#WebHidAllowAllDevicesForUrls) * [WebHidAllowDevicesForUrls](https://chromeenterprise.google/policies/#WebHidAllowDevicesForUrls) * [WebHidAllowDevicesWithHidUsagesForUrls](https://chromeenterprise.google/policies/#WebHidAllowDevicesWithHidUsagesForUrls) * [WebHidAskForUrls](https://chromeenterprise.google/policies/#WebHidAskForUrls) * [WebHidBlockedForUrls](https://chromeenterprise.google/policies/#WebHidBlockedForUrls) For more details, see [Set ChromeOS devices policies](https://support.google.com/chrome/a/answer/1375678) in the Chrome Enterprise and Education Help Center.

Also tagged: Progressive Web Apps Security & Authentication

USBDevice forget()

Following the recent HIDDevice forget() addition[1] to the web platform, the USBDevice forget() method allows web developers to voluntarily revoke a permission to a USBDevice that was granted by a user. [1] https://groups.google.com/a/chromium.org/g/blink-dev/c/Fk-IJF63UWc

Also tagged: Progressive Web Apps Security & Authentication

Web Bluetooth API

Allows web sites to communicate over GATT with nearby user-selected Bluetooth devices in a secure and privacy-preserving way. Status in Chrome is more complicated than can be captured by this form. In Chrome 56, this shipped on Android, ChromeOS, and macOS. In Chrome 70 it is shipping on Windows 10. For earlier versions of Windows and Linux, it is still behind a flag (chrome://flags/#enable-experimental-web-platform-features).

Also tagged: Media & Real-time Communication Privacy & Identity

Web Bluetooth exclusionFilters option in requestDevice()

The "exclusionFilters" option in navigator.bluetooth.requestDevice() allows web developers to exclude some devices from the browser picker. It can be used to exclude devices that match a broader filter but are unsupported.

Web Bluetooth getAvailability()

getAvailability() returns a promise that resolves with true if the user agent is running on a system that has a Bluetooth radio and false otherwise. The powered state of the Bluetooth radio does not influence the availability because applications can prompt users to turn on the radio using requestDevice(). The availabilitychanged event can be used to detect changes in the availability of the Bluetooth radio.

Web Bluetooth manufacturer data filter

Being able to filter based on manufacturer specific data (such as vendor ID and product ID) will enable e.g. manufacturer.example.com to configure/select only its own Bluetooth devices and present them to users, instead of showing unrelated Bluetooth devices in the browser picker.

Web Bluetooth Write With/Without Response

Implements two APIs for writing to GATT characteristics that will allow an app to ignore a response from the device or to expect a response from the device. The currently implemented writeValue() method will remain for backwards compatibility, but is discouraged.

Also tagged: Performance & Scheduling

Web Serial API

The Serial API provides an interface for connecting to serial devices, either through a serial port on the user’s system or removable USB and Bluetooth devices that emulate a serial port. This API has been requested by the hardware developer community, especially developers building educational tools, as a companion to the WebUSB API because operating systems require applications to communicate with USB-based serial ports using their higher-level serial API rather than the low-level USB API.

Web Serial support for Bluetooth RFCOMM services

Support Bluetooth RFCOMM services in the Web Serial API. The Bluetooth RFCOMM (Radio frequency communication) protocol provides emulated RS-232 serial ports. This feature would enable applications to make connections to RFCOMM services on paired Bluetooth Classic devices using the Web Serial API.

Web Serial: connected attribute and RFCOMM connection events

This feature adds a boolean SerialPort.connected attribute. The attribute is true if the serial port is logically connected. For wired serial ports, a port is logically connected if the port is physically attached to the system. For wireless serial ports, a port is logically connected if the device hosting the port has any open connections to the host. Previously, only wired serial ports dispatched connect and disconnect events. With this feature, Bluetooth RFCOMM serial ports will dispatch these events when the port becomes logically connected or disconnected. This feature is intended to allow applications to detect when a Bluetooth RFCOMM serial port is available without opening the port.

WebHID on Dedicated Workers

WebHID is enabled inside dedicated worker contexts. This allows developers to perform heavy I/O and processing of data from a HID device on a separate thread to reduce the performance impact on the main thread.

Also tagged: Performance & Scheduling

WebUSB API

The web platform API to support programming USB devices.

WebUSB exclusionFilters option in requestDevice()

The "exclusionFilters" option in navigator.usb.requestDevice() allows web developers to exclude some devices from the browser picker. It can be used to exclude devices that match a broader filter but are unsupported.

WebUSB in Extension Service Workers

Allows web developers to use WebUSB API when responding to extension events by exposing WebUSB API to Service Workers registered by browser extensions. This API will not yet be exposed to Service Workers registered by sites but the implementation experience gained by supporting the API for extensions will be valuable for such a future project.

Also tagged: Performance & Scheduling Progressive Web Apps

WebUSB on Dedicated Workers

WebUSB is enabled inside dedicated worker contexts. This allows developers to perform heavy I/O and processing of data from a USB device on a separate thread to reduce the performance impact on the main thread.

Also tagged: Performance & Scheduling

In developer trial (Behind a flag) (3)

Freezing on Energy Saver

When Energy Saver is active, Chrome will freeze a "browsing context group" that has been hidden and silent for >5 minutes if any subgroup of same-origin frames within it exceeds a CPU usage threshold, unless it: - Provides audio- or video-conferencing functionality (detected via microphone, camera or screen/window/tab capture or an RTCPeerConnection with an 'open' RTCDataChannel or a 'live' MediaStreamTrack). - Controls an external device (detected via usage of Web USB, Web Bluetooth, Web HID or Web Serial). - Holds a Web Lock or an IndexedDB connection that blocks a version update or a transaction on a different connection. - Participates in the freezing opt-out origin trial. Freezing consists of pausing execution. It is formally defined in the Page Lifecycle API. The CPU usage threshold will be calibrated to freeze approximately 10% of background tabs when Energy Saver is active. ** Note: The origin trial is to opt-out from freezing, not to activate it. **

Also tagged: Media & Real-time Communication Performance & Scheduling Storage & Files

Unrestricted WebUSB (available only to Isolated Web Apps)

Enables trusted applications to bypass security restrictions in the WebUSB API. The WebUSB specification defines a blocklist of vulnerable devices and a table of protected interfaces classes that are blocked from access through WebUSB. With this feature, Isolated Web Apps with permission to access the "usb-unrestricted" Permission Policy feature will be allowed to access blocklisted devices and protected interface classes.

Also tagged: Progressive Web Apps Security & Authentication

Web Bluetooth getDevices() and forget()

Chrome's implementation of Web Bluetooth does not have a way for websites to get a list of permitted devices. This feature adds the Bluetooth.getDevices() and BluetoothDevice.forget methods. getDevices() will return a list of BluetoothDevice objects that the current origin has been granted permission to use by the user. forget() will allow web developers to voluntarily revoke a permission to a BluetoothDevice that was granted by a user.

Also tagged: Security & Authentication

In development (1)

Web serial over Bluetooth on Android

This feature allows web pages and web apps to connect to serial ports over Bluetooth on Android devices. Chrome on Android now supports Web Serial API over Bluetooth RFCOMM. Existing enterprise policies (DefaultSerialGuardSetting, SerialAllowAllPortsForUrls, SerialAllowUsbDevicesForUrls, SerialAskForUrls and SerialBlockedForUrls) on other platforms are enabled in future_on states for Android. All policies except SerialAllowUsbDevicesForUrls will be enabled after the feature is enabled. SerialAllowUsbDevicesForUrls will be enabled in a future launch after Android provides system level support of wired serial ports.

Also tagged: Progressive Web Apps

Proposed (7)

Deprecate BluetoothRemoteGATTCharacteristic.writeValue()

The writeValue() method on BluetoothRemoteGATTCharacteristic is being deprecated. It is replaced by two new methods, writeValueWithResponse() and writeValueWithoutResponse(), which give developers explicit control over the type of write performed. The original writeValue() method is ambiguous, leading to two issues for developers: Platform Inconsistency: The behavior of writeValue() differs across platforms. For example, Chrome on Android defaults to a fast "write without response," while other platforms default to a reliable "write with response." This makes it impossible to write predictable, cross-platform compatible code. Lack of Developer Control: Developers are best equipped to decide between a high-throughput write (e.g., for a firmware update) and a guaranteed-delivery write (e.g., for a critical command). writeValue() hides this choice, preventing developers from implementing the correct logic for their application.

Direct Sockets API in Shared/Service workers

Allows Isolated Web Apps to establish direct transmission control protocol (TCP) and user datagram protocol (UDP) communications with network devices and systems as well as listen to and accept incoming connections from shared /service workers. The Direct Sockets API has been launched in Chrome 131 for window & dedicated worker contexts; this separate entry aims at expanding these to accommodate shared / service workers to achieve parity with the exposure of other networking capabilities such as fetch() or WebSockets. See https://chromestatus.com/feature/6398297361088512 for more context.

Also tagged: Performance & Scheduling Progressive Web Apps

Selective Permissions Intervention

When a user grants a website permission to access a powerful API (specifically Bluetooth, Camera, Clipboard, DisplayCapture, Geolocation, Microphone, Serial, and USB), their consent is intended for the site, not necessarily to every third-party script running on the page. In particular, embedded ad scripts running in the main frame or same-origin iframes can currently leverage the page's permission to opportunistically access this sensitive data. The user may not be aware that an advertisement is accessing their information. This intervention aims to better align a granted permission with user intent by preventing ad script in a context with API permission from using it, reinforcing user trust and control over their data.

Also tagged: Media & Real-time Communication Privacy & Identity Security & Authentication

Web Bluetooth: BluetoothRemoteGATTServer.maxWriteWithoutResponseSize

Adds BluetoothRemoteGATTServer.maxWriteWithoutResponseSize, which reports the largest payload that writeValueWithoutResponse() can send in one ATT packet. A maxwritewithoutresponsesizechanged event notifies applications when Chrome observes the value change, allowing applications to size chunks without assuming a 20-byte limit. it depends on: https://chromestatus.com/feature/5138797158334464 and will be shipped together. implementation: https://chromium-review.googlesource.com/c/chromium/src/+/7879985 Bug: 40265040, 40686244, 40163619

Web Serial API on Android

The Web Serial API provides an interface for connecting to serial devices, either through a serial port on the user’s system or removable USB and Bluetooth devices that emulate a serial port. Now it is supported on Android. Users, especially in the educational, hobbyist and industrial sectors, connect peripheral devices to their computers that require custom software to control. For example, robotics are often used to teach computer programming and electronics in schools. This requires software which can upload code to a robot and/or control it remotely. In an industrial or hobbyist setting a piece of equipment such as a mill, laser cutter or 3D printer is controlled by a program running on a connected computer. These devices are often controlled by small microcontrollers via a serial connection. Documentation: https://web.dev/serial/ Specification: https://wicg.github.io/serial/

No longer pursuing (1)

Web Bluetooth BluetoothDevice.watchAdvertisements()

The BluetoothDevice.watchAdvertisements() method will enable web apps to receive events when the system receives an advertisement packet from a watched device. Note: [10/31/2023] To clarify why the feature is no longer pursued, the function of `watchAdvertisement` will be integrated into `requestLEScan` with updated `BluetoothLEScanOptions`. With that change, the new flag `listenOnlyGrantedDevices` in the option could be used to listen to all granted bluetooth devices' advertisement events without iterating through each `BluetoothDevice`. Here is the explainer for more detail: https://github.com/WebBluetoothCG/web-bluetooth/blob/main/requestLEScan-for-granted-devices-explainer.md

Also tagged: Progressive Web Apps Security & Authentication

No active development (1)

Timeline