How To Use The Web Bluetooth API · confidence.sh
April 2, 2024
In this article, I’ll show you how to build using the Web Bluetooth API to interact with Bluetooth peripherals. We’ll specifically build together an app powered by Web Bluetooth to display stats from a Bluetooth enabled heart monitoring device like a smartwatch or a Bluetooth fitness tracker. If you own any of these, get them ready!
Web Bluetooth is a browser API we’ve covered before at our conferences. Associated with Project Fugu (also covered multiple times) it’s a privacy and security first way of using bluetooth in the browser.
Sadly Apple has stated their intent to not implement the API, citing privacy and security concerns (that are addressed at the very outset in the specification) which is a particular issue since Safari on iOS is the only way Web Bluetooth could get iPhone support for now. But perhaps recent efforts by regulators around the work, particularly in the EU will render this less of an issue by requiring Apple to allow non-Apple browser engines on iOS devices.