Do these 3 things before closing this tab:
1Scan for outdated or missing drivers - takes under a minute2Repair Windows errors before they cause bigger problems3Fix the driver behind crashes, sound loss and screen glitchesUse Web Bluetooth from a secure page and a user-initiated event: call navigator.bluetooth.requestDevice() with a service filter, connect to the device’s GATT server, then read, write, or subscribe to the characteristic your peripheral exposes. The API is for Bluetooth Low Energy (BLE), not arbitrary Bluetooth Classic devices, and browser support is limited. This complete example shows the permission flow, GATT operations, disconnect handling, iframe policy requirements, and the failures you need to handle in production.
What Web Bluetooth actually connects to
The Web Bluetooth API lets a page communicate with a Bluetooth Low Energy peripheral through its Generic Attribute Profile (GATT) server. A GATT server publishes services, and each service contains characteristics that can be read, written, or monitored for notifications. Your JavaScript must know the service and characteristic UUIDs (or standardized names) implemented by the target device.
This is not a general-purpose Bluetooth API. A peripheral that exposes only Bluetooth Classic profiles will not work through Web Bluetooth. Treat the device’s GATT documentation as a prerequisite: it should identify the primary service, characteristic properties (read, write, notify, and so on), data format, and whether authentication is required.
Browser and page requirements
Use a secure context
Web Bluetooth is restricted to secure contexts. Deploy over HTTPS; during local development, use a browser-supported secure localhost origin. An insecure HTTP deployment will fail before the chooser can be used.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
#1 Best Overall
- Bluetooth 5.4 + Broad Compatibility - Provides Bluetooth 5.4 plus EDR technology and is backward compatible with Bluetooth V5.3/5.0/4.2/4.0/3.0/2.1/2.0/1.1.
- Faster Speed, Extended Range - Get up to 2x faster data transfer and 4x broader coverage compared to Bluetooth 4.0 — perfect for smooth audio streaming and stable connections.
- EDR and BLE Technology - This Bluetooth dongle is quipped with enhanced data rate and Bluetooth low energy, UB500 has greatly improved data transfer speed and operates at the optimal rate of power consumption
- Nano-Sized - A sleek, ultra-small design means you can insert the Nano Bluetooth receiver into any USB port and simply keep it there regardless of whether you are traveling or at home
- Plug & Play with Free Driver Support - Plug and play for Windows 8.1/10/11 (internet required). Supports Win7 (driver required and can be downloaded from website for free). Download the latest driver from TP-Link website to utilize Bluetooth 5.4
Start from a user gesture
requestDevice() requires transient user activation. Call it directly from a click or another user-initiated event, rather than on page load, in a timer, or after an unrelated asynchronous task. Browsers use this gesture requirement to make the device-selection and permission decision visible to the user.
Check availability, but do not trust it as a guarantee
navigator.bluetooth.getAvailability() can provide a hint about whether Bluetooth appears available. It does not prove that an adapter is powered, that policy allows access, that a matching peripheral is nearby, or that the user will grant permission. Always handle errors from the chooser and subsequent GATT calls.
Verify support on your target browser
MDN classifies Web Bluetooth as experimental and limited availability (not Baseline). Support differs by browser, operating system, and device. Feature-detect navigator.bluetooth and check the live browser compatibility table for the platforms you intend to ship; do not promise universal support.
Minimal working example
The following page connects when the user clicks a button, reads the standard Battery Service, displays the first byte as a percentage, and reports disconnects. It is illustrative: the peripheral must actually expose battery_service and battery_level.
Rank #2
- 【Enjoy Wireless Streaming Music】This car Bluetooth adapter can be connected to non-Bluetooth car audio systems, home stereos, speakers, wired headphones via the 3.5mm AUX adapter; And equipped with a Bluetooth 5.0 chip for stable connection / fast transmission / wide signal range. Just pair it with your phone and start listening to your favorite music!
- 【Intelligent Noise Reduction Tech】Our Bluetooth audio receiver adopts the latest CVC8.0 Noise Cancellation and Digital Signal Processor (DSP) technologies, which can eliminate echo and block out intrusive background noise (such as wind, traffic, or crowds), providing you with crystal-clear calling sounds.
- 【Up to 16 Hours of Battery Life】The working time of this aux Bluetooth adapter is up to 16 hours when making calls or playing music. And it takes only 2.5 hours to fully charge the device by using a Type-C fast charging cable (Included in the package). In addition, this Bluetooth music adapter can be used while charging, which is very convenient.
- 【Hands-free Calling & Navigation】A built-in microphone and one “MFB” button to answer / redial / hang up / reject calls, help you make hands-free calls. And the Bluetooth audio adapter supports broadcasting voice notification from existed navigation App. You don’t have to look down the phone on the move. Make sure you drive safely!
- 【Dual Connection】The portable Bluetooth stereo adapter can be paired with 2 devices at the same time. You can enjoy your music and never worry about missing any calls. Once paired, the car receiver will automatically reconnect to your last paired Bluetooth devices, as long as they are within the wireless range.
<button id="connect" type="button">Connect to BLE device</button>
<output id="status" role="status">Not connected</output>
<script>
const button = document.querySelector("#connect");
const status = document.querySelector("#status");
function show(message) {
status.textContent = message;
}
button.addEventListener("click", async () => {
if (!navigator.bluetooth) {
show("Web Bluetooth is unavailable in this browser.");
return;
}
try {
show("Choose a nearby device…");
const device = await navigator.bluetooth.requestDevice({
filters: [{ services: ["battery_service"] }]
});
device.addEventListener("gattserverdisconnected", () => {
show("Device disconnected.");
});
show("Connecting…");
const server = await device.gatt.connect();
const service = await server.getPrimaryService("battery_service");
const characteristic = await service.getCharacteristic("battery_level");
const value = await characteristic.readValue();
show(`Battery: ${value.getUint8(0)}%`);
} catch (error) {
show(`${error.name}: ${error.message}`);
console.error(error);
}
});
</script>
Replace the service and characteristic identifiers with those documented by your peripheral. A standard identifier in an example is not evidence that every device implements it.
Choosing devices: filters versus accepting everything
Prefer service filters
A filter limits the chooser to devices advertising a matching service and gives the page authorization to access that service. You can include multiple filters when several device profiles are acceptable:
const device = await navigator.bluetooth.requestDevice({
filters: [
{ services: ["battery_service"] },
{ namePrefix: "Sensor-", services: ["0000fff0-0000-1000-8000-00805f9b34fb"] }
]
});
Use the UUID format and property names supported by the browser. A filter that is too narrow produces an empty chooser even when the peripheral is nearby.
Use acceptAllDevices only when you need broad selection
For a name-based or otherwise broad workflow, you may set acceptAllDevices: true. This option cannot be combined with filters, and it does not automatically authorize arbitrary services. List every service you will access in optionalServices:
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Rank #3
- Listen music wireless: Connect with computer speakers, home stereo systems or other speaker systems via the 3.5 mm or RCA cable, then pair with the Bluetooth audio devices such as smartphones or tablet for streaming music.
- Easy setup and automatic reconnect: There is a big bluetooth symbol button in bluetooth receiver middle. Pair your bluetooth device to this adapter with a single button press. Click once means Bluetooth Connect/Disconnect. Hold the botton 3 second mean ON/OFF. It can reconnect automatically with the previously paired device.
- Wireless range: Indoors(without obstacles) connect rang up 30-40 ft (10-12 m).
- Works with most device: Bluetooth enabled device including smartphones, tablets, computers, laptops upon and any powered PC speakers, home stereo systems and A/V receivers.
- NOTE: This adapter doesn't have built-in battery, power by AC to DC power adapter or USB cable. This product is a bluetooth receiver ONLY, not a bluetooth transmitter. Only to give Bluetooth capabilities to an existing stereo / powered speaker / PA. If you have any problems, please contact us at any time by Amazon Order, and we will speed up the process to resolve the issue.
const device = await navigator.bluetooth.requestDevice({
acceptAllDevices: true,
optionalServices: [
"battery_service",
"device_information",
"0000fff0-0000-1000-8000-00805f9b34fb"
]
});
If you select by name or name prefix, still include the required service UUIDs in optionalServices. After selection, the page can access only services granted by the filter or optional-service list.
Reading, writing, and notifications
Read a characteristic
const value = await characteristic.readValue();
const firstByte = value.getUint8(0);
const text = new TextDecoder().decode(value);
Interpret the returned DataView according to the peripheral’s protocol. Multi-byte values may require an explicit byte order, scaling factor, or checksum.
Write bytes
const command = new Uint8Array([0x01, 0x00]);
await characteristic.writeValue(command);
The characteristic must advertise a write property. Some devices distinguish write-with-response from write-without-response; use the operation exposed by the browser and device, and observe the peripheral’s packet-size and timing rules.
Subscribe to notifications
await characteristic.startNotifications();
characteristic.addEventListener("characteristicvaluechanged", event => {
const bytes = new Uint8Array(event.target.value.buffer);
console.log("Notification bytes", bytes);
});
Stop notifications when the page no longer needs them:
Rank #4
- Upgraded Bluetooth 5.3 Adapter: This bluetooth adapter for pc uses the latest upgraded Bluetooth 5.3 BR+EDR technology, greatly improves the stability of the connection data transfer speed, reduces the possibility of signal interruption and power consumption.
- Up to 5 Devices Sync Connected: UGREEN Bluetooth dongle for PC supports up to 5 different types of Bluetooth devices to be connected at the same time without interfering with each other, such as Bluetooth mouse/keyboard/mobile phone/headphones, etc. If Bluetooth audio devices of the same type (such as speakers/headphones) are connected, only one device can play music.
- Plug and Play: The Bluetooth adapter is developed for Windows systems only and does not support other systems. No driver installation is required under Windows 11/10/8.1. NOTE: Win 7, Linux and MacOS System are NOT supported.
- Mini Size: An extremely compact Bluetooth stick that you can leave on your laptop or PC without removing it.The compact size does not interfere with other USB ports. Convenient to carry, no space occupation.
- What Can I do if the Bluetooth adapter can not work?: Ensure there are no other Bluetooth devices installed on the computer. If there are, disable all existing Bluetooth devices in "Device Manager", then insert the adapter and try again. (For detailed information please read the user manual)
await characteristic.stopNotifications();
Reconnect after a drop
device.addEventListener("gattserverdisconnected", async () => {
show("Disconnected. Click Connect to try again.");
// Reconnect only when your UX and device allow it:
// await device.gatt.connect();
});
A disconnect can be caused by leaving range, powering down the peripheral, radio interference, or a peripheral-side error. Reconnecting is asynchronous and can fail again; provide a visible retry path instead of assuming the link is permanent.
Cross-origin iframe and Permissions Policy
The bluetooth Permissions Policy defaults to self. A top-level page can use the API without an iframe delegation, but a cross-origin embedded page needs both server policy permission and an iframe attribute. For example, the embedding response must authorize the embedded origin, and the iframe must include:
<iframe
src="https://widget.example/ble.html"
allow="bluetooth">
</iframe>
The exact policy header must name the origin you trust. If either the response policy or the iframe’s allow attribute is missing, the chooser can be blocked even in a browser that otherwise supports Web Bluetooth. Keep the delegation as narrow as possible.
Failure diagnosis
| Symptom | Likely cause | Fix |
|---|---|---|
navigator.bluetooth is undefined |
Unsupported browser, platform, or insecure context | Serve HTTPS, feature-detect, and verify support for the target browser and operating system. |
| Chooser never opens | Call was not triggered by a transient user activation | Invoke requestDevice() directly inside the click handler; do not defer it behind timers or unrelated awaits. |
| No devices appear | Peripheral is off, out of range, not advertising the filtered service, or the filter is wrong | Confirm advertising and UUIDs, temporarily test a known service filter, and keep the device close to the computer or phone. |
| Permission or policy error | Denied prompt, blocked bluetooth policy, or missing iframe delegation |
Allow the device, check site permissions, and configure the response policy plus allow="bluetooth" for cross-origin frames. |
getPrimaryService() fails |
The service was not authorized or the device does not expose it as a primary service | Add the UUID to a filter or optionalServices, then verify the peripheral’s GATT table. |
| Characteristic lookup fails | Wrong UUID or characteristic belongs to another service | Use the peripheral’s exact characteristic UUID and retrieve it from the correct service. |
| Read or write fails | Characteristic lacks that property, data is malformed, or the link dropped | Check characteristic properties and payload format, then handle disconnects and retry deliberately. |
| Works once, then stops | Device disconnected or notifications were not re-established | Listen for gattserverdisconnected, show connection state, and reconnect and restart notifications only after success. |
Production checklist
- Run from HTTPS and test the exact browser/OS combinations you support.
- Call the chooser from a clearly labeled user action.
- Use the narrowest service filters practical; use
optionalServicesonly for services needed after selection. - Display permission, connecting, connected, and disconnected states.
- Validate every byte received from the peripheral before using it.
- Handle cancellation, denied permission, missing devices, GATT errors, and radio disconnects.
- Do not treat
getAvailability()as proof that a connection will work. - For iframes, configure both the HTTP Permissions Policy and the iframe
allowattribute. - Never request more services than the feature needs; users should understand what device access they are granting.
Or skip the browser setup
If your goal is a visual capture of a Bluetooth dashboard, documentation page, or test result rather than a BLE connection itself, ScreenshotNeo can return a screenshot or PDF with one request. It accepts consent banners before capture and removes more than 60 known consent platforms, newsletter popups, and chat widgets; bot checks, blank pages, timeouts, failed loads, and cache hits are not billed, and response headers identify the page verdict and billing status. Its MCP server provides take_screenshot, get_page_info, and capture_pdf tools for Claude, Cursor, and other MCP clients.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →See the complete parameters in the ScreenshotNeo API documentation. A direct call looks like this:
Best Value
- INSTANT BLUETOOTH ACCESS: Bluetooth dongle adapter receiver for PCs converts non-Bluetooth devices into Bluetooth-capable with simple USB connection
- WIDE COMPATIBILITY: Supports Bluetooth 5.4 and is backwards compatible with Bluetooth 5.3/5.2/5.1/5.0/V4.2/4.0/3.0/2.1/2.0/1.1; ONLY works with Windows 8.1, 10, and 11
- MULTI-DEVICE CONNECTION: Connect up to 6 devices simultaneously; Not compatible with all other operation systems e.g. Mac, Linux, Chrome, Unix, Playstation(PS), Windows 7 and below; Nano bluetooth receiver can be plugged in via any standard USB port
- ENHANCED PERFORMANCE: EDR and BLE technology offers enhanced data rate/transfer speed and low energy consumption
- SYSTEM REQUIREMENTS: Not compatible with all other operation systems e.g. Mac, Linux, Chrome, Unix, Playstation(PS), Windows 7 and below; Disable any built-in Bluetooth of the device before use this product, refer to the user manual for detail
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
The Free plan includes 1,000 screenshots each month with no card; paid plans start at $5 for 3,000 shots. Create a free ScreenshotNeo account to get started.
Frequently asked questions
Can JavaScript connect to Bluetooth Classic?
No. Web Bluetooth targets Bluetooth Low Energy peripherals exposed through GATT. A Classic-only device needs a different integration, such as a native application or a device that also offers BLE services.
Can a page reconnect automatically on reload?
Do not assume it can. Store only the state your application needs, request the device through the browser’s permission model, and be prepared for the user to select it again or for the connection to fail.
Why does a device appear but its service is inaccessible?
Selection and authorization are separate. Add the service to a filter or optionalServices, and confirm that the UUID and service type match the peripheral’s GATT definition.
Is getAvailability() enough for a “Bluetooth supported” check?
No. It is only an availability hint. The real chooser, permission decision, adapter state, device advertising, and GATT connection can still fail.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




