---
description: Capacitor plugin for Bluetooth Low Energy (BLE) communication with advanced features like headless tasks, foreground services, and more.
title: Capacitor Bluetooth Low Energy Plugin for Android & iOS - Capawesome
image: https://capawesome.io/docs/assets/images/social/plugins/bluetooth-low-energy.png
---

[ Skip to content](#capawesome-teamcapacitor-bluetooth-low-energy) 

[ 🎉 Introducing **Capawesome Platform** — one platform for Live Updates, Native Builds, App Store Publishing, and Insider SDKs.](https://capawesome.io) 

* [  iOS ](#ios)
* [  Configuration ](#configuration)
* [  Usage ](#usage)
* [  API ](#api)
* [  Type Aliases ](#type-aliases)
* [  Enums ](#enums)
* [  Utils ](#utils)
* [  Changelog ](#changelog)
* [  Breaking Changes ](#breaking-changes)
* [  License ](#license)
* [  Cloudinary ](/docs/plugins/cloudinary/)
* [  Contacts ](/docs/plugins/contacts/)
* [  Datetime Picker ](/docs/plugins/datetime-picker/)
* [  File Compressor ](/docs/plugins/file-compressor/)
* [  File Opener ](/docs/plugins/file-opener/)
* [  File Picker ](/docs/plugins/file-picker/)
* [  Firebase ](/docs/plugins/firebase/)
* [  Formbricks ](/docs/plugins/formbricks/)
* [  Geocoder ](/docs/plugins/geocoder/)
* [  Google Sign-In ](/docs/plugins/google-sign-in/)
* [  libSQL ](/docs/plugins/libsql/)
* [  Live Update ](/docs/plugins/live-update/)
* [  Managed Configurations ](/docs/plugins/managed-configurations/)
* [  Media Session ](/docs/plugins/media-session/)
* [  ML Kit ](/docs/plugins/mlkit/)
* [  NFC ](/docs/plugins/nfc/)
* [  OAuth ](/docs/plugins/oauth/)
* [  Pedometer ](/docs/plugins/pedometer/)
* [  Photo Editor ](/docs/plugins/photo-editor/)
* [  PostHog ](/docs/plugins/posthog/)
* [  Printer ](/docs/plugins/printer/)
* [  Purchases ](/docs/plugins/purchases/)
* [  RealtimeKit ](/docs/plugins/realtimekit/)
* [  Screen Orientation ](/docs/plugins/screen-orientation/)
* [  Screenshot ](/docs/plugins/screenshot/)
* [  Secure Preferences ](/docs/plugins/secure-preferences/)
* [  Speech Recognition ](/docs/plugins/speech-recognition/)
* [  Speech Synthesis ](/docs/plugins/speech-synthesis/)
* [  Share Target ](/docs/plugins/share-target/)
* [  Square Mobile Payments ](/docs/plugins/square-mobile-payments/)
* [  SQLite ](/docs/plugins/sqlite/)
* [  Superwall ](/docs/plugins/superwall/)
* [  Torch ](/docs/plugins/torch/)
* [  Wifi ](/docs/plugins/wifi/)
* [  Zip ](/docs/plugins/zip/)
* [  Cloud ](/docs/cloud/)
* [  Live Updates ](/docs/cloud/live-updates/)
* Advanced
* Integrations
* [  Native Builds ](/docs/cloud/native-builds/)
* [  Configuration ](/docs/cloud/native-builds/configuration/)
* [  Environments ](/docs/cloud/native-builds/environments/)
* Guides
* [  Sample Projects ](/docs/cloud/native-builds/sample-projects/)
* [  Troubleshooting ](/docs/cloud/native-builds/troubleshooting/)
* [  Automations ](/docs/cloud/automations/)
* [  Assist ](/docs/cloud/assist/)
* Account
* Organizations
* [  Organization and User Management ](/docs/cloud/organizations/memberships/)
* [  Single Sign-On (SSO) ](/docs/cloud/organizations/sso/)
* [  Teams ](/docs/cloud/organizations/teams/)
* [  Two-Factor Authentication ](/docs/cloud/organizations/two-factor-authentication/)
* [  Integrations ](/docs/cloud/integrations/)
* [  License Keys ](/docs/cloud/license-keys/)
* [  Webhooks ](/docs/cloud/webhooks/)
* [  Pricing ](https://capawesome.io/pricing/)
* [  FAQ ](/docs/cloud/faq/)
* [  Support ](/docs/cloud/support/)
* [  Contributing ](/docs/contributing/)
* [  LLMs ](/docs/llms/)
* [  Insiders ](/docs/insiders/)
* [  License ](https://capawesome.io/legal/eula/)
* [  Support ](/docs/insiders/support/)
* [  FAQ ](/docs/insiders/faq/)
* [  Blog ](/blog/)
* Categories

* [  iOS ](#ios)
* [  Configuration ](#configuration)
* [  Usage ](#usage)
* [  API ](#api)
* [  Type Aliases ](#type-aliases)
* [  Enums ](#enums)
* [  Utils ](#utils)
* [  Changelog ](#changelog)
* [  Breaking Changes ](#breaking-changes)
* [  License ](#license)

# @capawesome-team/capacitor-bluetooth-low-energy[¶](#capawesome-teamcapacitor-bluetooth-low-energy "Permanent link")

Capacitor plugin for Bluetooth Low Energy (BLE) communication in the central and peripheral role with advanced features like headless tasks, foreground services, and more.

[ ![Deliver Live Updates to your Capacitor app with Capawesome Cloud](../../assets/external/cloud.capawesome.io/assets/banners/cloud-build-and-deploy-capacitor-apps.69628c3f.png) ](https://cloud.capawesome.io/) 

## Features[¶](#features "Permanent link")

We are proud to offer one of the most complete and feature-rich Capacitor plugins for Bluetooth Low Energy communication. Here are some of the key features:

* 🖥️ **Cross-platform**: Supports Android and iOS.
* 🔄 **Central Role**: Communicate with BLE peripherals as a central device.
* 📳 **Peripheral Role**: Act as a BLE peripheral to communicate with other central devices.
* 🦾 **Headless Task**: Add custom native code for specific events.
* 🌙 **Foreground Service**: Keep the connection alive even when the app is in the background.
* 🔌 **Auto Reconnection**: Automatically reconnect to peripherals when the connection is lost.
* ⏳ **Command Queue**: Queue up incoming commands to prevent operation failures.
* 📱 **Multiple Devices**: Connect to multiple devices at the same time.
* 🛠️ **Utils**: Utility functions to make your life easier.
* ⚔️ **Battle-Tested**: Used in more than 300 projects.
* 📦 **CocoaPods & SPM**: Supports CocoaPods and Swift Package Manager for iOS.
* 🔁 **Up-to-date**: Always supports the latest Capacitor version.
* ⭐️ **Support**: Priority support from the Capawesome Team.
* ✨ **Handcrafted**: Built from the ground up with care and expertise, not forked or AI-generated.

Missing a feature? Just [open an issue](https://github.com/capawesome-team/capacitor-plugins/issues) and we'll take a look!

## Testimonials[¶](#testimonials "Permanent link")

> We migrated PadelBand, a sports tech app, from the Capacitor Community BLE plugin to this one and the difference is remarkable. The reliable background support and the ability to run custom native code with headless tasks made all the difference for our use case. Highly recommended!

\-- [PadelBand](https://padel-band.com) Development Team

## Newsletter[¶](#newsletter "Permanent link")

Stay up to date with the latest news and updates about the Capawesome, Capacitor, and Ionic ecosystem by subscribing to our [Capawesome Newsletter](https://cloud.capawesome.io/newsletter/).

## Compatibility[¶](#compatibility "Permanent link")

| Plugin Version | Capacitor Version | Status         |
| -------------- | ----------------- | -------------- |
| 8.x.x          | \>=8.x.x          | Active support |
| 7.x.x          | 7.x.x             | Deprecated     |
| 6.x.x          | 6.x.x             | Deprecated     |

## Demo[¶](#demo "Permanent link")

A working example can be found [here](https://github.com/capawesome-team/capacitor-heart-rate-monitor-app).

| Android                                                                                                            | iOS                                                                                                            |
| ------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------- |
| ![Android Demo](../../assets/external/github.com/user-attachments/assets/c4cf7ddc-7f98-42e1-8334-34a26dfdf457.gif) | ![iOS Demo](../../assets/external/github.com/user-attachments/assets/3cfac38f-22ef-4b8e-a439-529079926a4e.gif) |

## Guides[¶](#guides "Permanent link")

* [Announcing the Capacitor Bluetooth Low Energy Plugin](https://capawesome.io/blog/announcing-the-capacitor-bluetooth-low-energy-plugin/)
* [How to Build a Heart Rate Monitor with Capacitor](https://capawesome.io/blog/how-to-build-a-heart-rate-monitor-with-capacitor/)

## Installation[¶](#installation "Permanent link")

This plugin is only available to [Capawesome Insiders](https://capawesome.io/insiders/). First, make sure you have the Capawesome npm registry set up. You can do this by running the following commands:

`[](#%5F%5Fcodelineno-0-1)npm config set @capawesome-team:registry https://npm.registry.capawesome.io
[](#%5F%5Fcodelineno-0-2)npm config set //npm.registry.capawesome.io/:_authToken <YOUR_LICENSE_KEY>
`

**Attention**: Replace `<YOUR_LICENSE_KEY>` with the license key you received from Polar. If you don't have a license key yet, you can get one by becoming a [Capawesome Insider](https://capawesome.io/insiders/).

Next, you can use our **AI-Assisted Setup** to install the plugin. Add the [Capawesome Skills](https://github.com/capawesome-team/skills) to your AI tool using the following command:

`[](#%5F%5Fcodelineno-1-1)npx skills add capawesome-team/skills --skill capacitor-plugins
`

Then use the following prompt:

`` [](#%5F%5Fcodelineno-2-1)Use the `capacitor-plugins` skill from `capawesome-team/skills` to install the `@capawesome-team/capacitor-bluetooth-low-energy` plugin in my project.
 ``

If you prefer **Manual Setup**, install the plugin by running the following commands and follow the platform-specific instructions below:

`[](#%5F%5Fcodelineno-3-1)npm install @capawesome-team/capacitor-bluetooth-low-energy
[](#%5F%5Fcodelineno-3-2)npx cap sync
`

### Android[¶](#android "Permanent link")

#### Features[¶](#features%5F1 "Permanent link")

Add the following element to your `AndroidManifest.xml` before or after the `application` tag:

`[](#%5F%5Fcodelineno-4-1)<uses-feature android:name="android.hardware.bluetooth_le" android:required="true" />
`

Set the `android:required` attribute to `true` if your app can't function, or isn't designed to function, when Bluetooth Low Energy is not available on the device. If your app can function without Bluetooth Low Energy, set the `android:required` attribute to `false`. This will allow your app to be installed on devices that do not support Bluetooth Low Energy.

#### Permissions[¶](#permissions "Permanent link")

This API requires the following elements be added to your `AndroidManifest.xml` before or after the `application` tag:

`[](#%5F%5Fcodelineno-5-1)<!-- Required if you want to support Android 11 and below. -->
[](#%5F%5Fcodelineno-5-2)<uses-permission android:name="android.permission.BLUETOOTH" android:maxSdkVersion="30" />
[](#%5F%5Fcodelineno-5-3)<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" android:maxSdkVersion="30" />
[](#%5F%5Fcodelineno-5-4)<!-- Required if you want to advertise as a BLE device. -->
[](#%5F%5Fcodelineno-5-5)<uses-permission android:name="android.permission.BLUETOOTH_ADVERTISE" />
[](#%5F%5Fcodelineno-5-6)<!-- Required if you want to scan for BLE devices. -->
[](#%5F%5Fcodelineno-5-7)<uses-permission android:name="android.permission.BLUETOOTH_SCAN" />
[](#%5F%5Fcodelineno-5-8)<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
[](#%5F%5Fcodelineno-5-9)<!-- Required if you want to be able to connect to paired Bluetooth devices. -->
[](#%5F%5Fcodelineno-5-10)<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
[](#%5F%5Fcodelineno-5-11)<!--Required if you want to start a foreground service.-->
[](#%5F%5Fcodelineno-5-12)<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
[](#%5F%5Fcodelineno-5-13)<uses-permission android:name="android.permission.FOREGROUND_SERVICE_CONNECTED_DEVICE" />
[](#%5F%5Fcodelineno-5-14)<uses-permission android:name="android.permission.WAKE_LOCK" />
`

You can read more about Bluetooth permissions in the [Android documentation](https://developer.android.com/develop/connectivity/bluetooth/bt-permissions).

#### Services[¶](#services "Permanent link")

You also need to add the following service **inside** the `application` tag in your `AndroidManifest.xml` (usually `android/app/src/main/AndroidManifest.xml`):

`[](#%5F%5Fcodelineno-6-1)<service android:name="io.capawesome.capacitorjs.plugins.bluetoothle.BluetoothLowEnergyService" android:foregroundServiceType="connectedDevice" />
`

#### Headless Task[¶](#headless-task "Permanent link")

If you want to run your own native code when a specific event occurs, you can create a headless task. For this, you need to create a Java class with the name `BluetoothLowEnergyHeadlessTask` in the same package as your `MainActivity`. Then implement the following methods:

`[](#%5F%5Fcodelineno-7-1)import android.bluetooth.BluetoothGatt;
[](#%5F%5Fcodelineno-7-2)import android.bluetooth.BluetoothGattCharacteristic;
[](#%5F%5Fcodelineno-7-3)import android.bluetooth.BluetoothGattDescriptor;
[](#%5F%5Fcodelineno-7-4)import androidx.annotation.NonNull;
[](#%5F%5Fcodelineno-7-5)
[](#%5F%5Fcodelineno-7-6)public class BluetoothLowEnergyHeadlessTask {
[](#%5F%5Fcodelineno-7-7)  public void onCharacteristicChanged(@NonNull BluetoothGatt gatt, @NonNull BluetoothGattCharacteristic characteristic) {
[](#%5F%5Fcodelineno-7-8)    // Your code here
[](#%5F%5Fcodelineno-7-9)  }
[](#%5F%5Fcodelineno-7-10)
[](#%5F%5Fcodelineno-7-11)  public void onCharacteristicChanged(@NonNull BluetoothGatt gatt, @NonNull BluetoothGattCharacteristic characteristic, @NonNull byte[] value) {
[](#%5F%5Fcodelineno-7-12)    // Your code here
[](#%5F%5Fcodelineno-7-13)  }
[](#%5F%5Fcodelineno-7-14)
[](#%5F%5Fcodelineno-7-15)  public void onCharacteristicRead(@NonNull BluetoothGatt gatt, @NonNull BluetoothGattCharacteristic characteristic, int status) {
[](#%5F%5Fcodelineno-7-16)    // Your code here
[](#%5F%5Fcodelineno-7-17)  }
[](#%5F%5Fcodelineno-7-18)
[](#%5F%5Fcodelineno-7-19)  public void onCharacteristicWrite(@NonNull BluetoothGatt gatt, @NonNull BluetoothGattCharacteristic characteristic, int status) {
[](#%5F%5Fcodelineno-7-20)    // Your code here
[](#%5F%5Fcodelineno-7-21)  }
[](#%5F%5Fcodelineno-7-22)
[](#%5F%5Fcodelineno-7-23)  public void onConnectionStateChange(@NonNull BluetoothGatt gatt, int status, int newState) {
[](#%5F%5Fcodelineno-7-24)    // Your code here
[](#%5F%5Fcodelineno-7-25)  }
[](#%5F%5Fcodelineno-7-26)
[](#%5F%5Fcodelineno-7-27)  public void onDescriptorRead(@NonNull BluetoothGatt gatt, @NonNull BluetoothGattDescriptor descriptor, int status, @NonNull byte[] value) {
[](#%5F%5Fcodelineno-7-28)    // Your code here
[](#%5F%5Fcodelineno-7-29)  }
[](#%5F%5Fcodelineno-7-30)
[](#%5F%5Fcodelineno-7-31)  public void onDescriptorWrite(@NonNull BluetoothGatt gatt, @NonNull BluetoothGattDescriptor descriptor, int status) {
[](#%5F%5Fcodelineno-7-32)    // Your code here
[](#%5F%5Fcodelineno-7-33)  }
[](#%5F%5Fcodelineno-7-34)
[](#%5F%5Fcodelineno-7-35)  public void onMtuChanged(@NonNull BluetoothGatt gatt, int mtu, int status) {
[](#%5F%5Fcodelineno-7-36)    // Your code here
[](#%5F%5Fcodelineno-7-37)  }
[](#%5F%5Fcodelineno-7-38)
[](#%5F%5Fcodelineno-7-39)  public void onReadRemoteRssi(@NonNull BluetoothGatt gatt, int rssi, int status) {
[](#%5F%5Fcodelineno-7-40)    // Your code here
[](#%5F%5Fcodelineno-7-41)  }
[](#%5F%5Fcodelineno-7-42)
[](#%5F%5Fcodelineno-7-43)  public void onServiceChanged(@NonNull BluetoothGatt gatt) {
[](#%5F%5Fcodelineno-7-44)    // Your code here
[](#%5F%5Fcodelineno-7-45)  }
[](#%5F%5Fcodelineno-7-46)
[](#%5F%5Fcodelineno-7-47)  public void onServicesDiscovered(@NonNull BluetoothGatt gatt, int status) {
[](#%5F%5Fcodelineno-7-48)    // Your code here
[](#%5F%5Fcodelineno-7-49)  }
[](#%5F%5Fcodelineno-7-50)}
`

#### Proguard[¶](#proguard "Permanent link")

If you are using Proguard, you need to add the following rules to your `proguard-rules.pro` file:

`[](#%5F%5Fcodelineno-8-1)-keep class io.capawesome.capacitorjs.plugins.** { *; }
`

### iOS[¶](#ios "Permanent link")

#### Privacy Descriptions[¶](#privacy-descriptions "Permanent link")

Add the `NSBluetoothAlwaysUsageDescription` key to the `Info.plist` file (usually `ios/App/App/Info.plist`), which tells the user why the app needs access to Bluetooth peripherals:

`[](#%5F%5Fcodelineno-9-1)<key>NSBluetoothAlwaysUsageDescription</key>
[](#%5F%5Fcodelineno-9-2)<string>The app needs access to Bluetooth peripherals to communicate with Bluetooth devices.</string>
`

#### Capabilities[¶](#capabilities "Permanent link")

If you want your app to maintain Bluetooth Low Energy connections in the background, ensure the `Background Modes` capability is enabled with `bluetooth-central` in your Xcode project. See [Add a capability to a target](https://help.apple.com/xcode/mac/current/#/dev88ff319e7) for more information.

## Configuration[¶](#configuration "Permanent link")

No configuration required for this plugin.

## Usage[¶](#usage "Permanent link")

`[](#%5F%5Fcodelineno-10-1)import { BluetoothLowEnergy, BluetoothLowEnergyUtils, ConnectionPriority } from '@capawesome-team/capacitor-bluetooth-low-energy';
[](#%5F%5Fcodelineno-10-2)
[](#%5F%5Fcodelineno-10-3)const connect = async () => {
[](#%5F%5Fcodelineno-10-4)  await BluetoothLowEnergy.connect({ deviceId: '00:00:00:00:00:00' });
[](#%5F%5Fcodelineno-10-5)};
[](#%5F%5Fcodelineno-10-6)
[](#%5F%5Fcodelineno-10-7)const createBond = async () => {
[](#%5F%5Fcodelineno-10-8)  await BluetoothLowEnergy.createBond({ deviceId: '00:00:00:00:00:00' });
[](#%5F%5Fcodelineno-10-9)};
[](#%5F%5Fcodelineno-10-10)
[](#%5F%5Fcodelineno-10-11)const disconnect = async () => {
[](#%5F%5Fcodelineno-10-12)  await BluetoothLowEnergy.disconnect({ deviceId: '00:00:00:00:00:00' });
[](#%5F%5Fcodelineno-10-13)};
[](#%5F%5Fcodelineno-10-14)
[](#%5F%5Fcodelineno-10-15)const discoverServices = async () => {
[](#%5F%5Fcodelineno-10-16)  await BluetoothLowEnergy.discoverServices({ deviceId: '00:00:00:00:00:00' });
[](#%5F%5Fcodelineno-10-17)};
[](#%5F%5Fcodelineno-10-18)
[](#%5F%5Fcodelineno-10-19)const getConnectedDevices = async () => {
[](#%5F%5Fcodelineno-10-20)  const result = await BluetoothLowEnergy.getConnectedDevices();
[](#%5F%5Fcodelineno-10-21)  return result.devices;
[](#%5F%5Fcodelineno-10-22)};
[](#%5F%5Fcodelineno-10-23)
[](#%5F%5Fcodelineno-10-24)const getServices = async () => {
[](#%5F%5Fcodelineno-10-25)  const result = await BluetoothLowEnergy.getServices({ deviceId: '00:00:00:00:00:00' });
[](#%5F%5Fcodelineno-10-26)  return result.services;
[](#%5F%5Fcodelineno-10-27)};
[](#%5F%5Fcodelineno-10-28)
[](#%5F%5Fcodelineno-10-29)const initialize = async () => {
[](#%5F%5Fcodelineno-10-30)  await BluetoothLowEnergy.initialize({ mode: 'central' });
[](#%5F%5Fcodelineno-10-31)};
[](#%5F%5Fcodelineno-10-32)
[](#%5F%5Fcodelineno-10-33)const isAvailable = async () => {
[](#%5F%5Fcodelineno-10-34)  const result = await BluetoothLowEnergy.isAvailable();
[](#%5F%5Fcodelineno-10-35)  return result.isAvailable;
[](#%5F%5Fcodelineno-10-36)};
[](#%5F%5Fcodelineno-10-37)
[](#%5F%5Fcodelineno-10-38)const isBonded = async () => {
[](#%5F%5Fcodelineno-10-39)  const result = await BluetoothLowEnergy.isBonded({ deviceId: '00:00:00:00:00:00' });
[](#%5F%5Fcodelineno-10-40)  return result.bonded;
[](#%5F%5Fcodelineno-10-41)};
[](#%5F%5Fcodelineno-10-42)
[](#%5F%5Fcodelineno-10-43)const isEnabled = async () => {
[](#%5F%5Fcodelineno-10-44)  const result = await BluetoothLowEnergy.isEnabled();
[](#%5F%5Fcodelineno-10-45)  return result.enabled;
[](#%5F%5Fcodelineno-10-46)};
[](#%5F%5Fcodelineno-10-47)
[](#%5F%5Fcodelineno-10-48)const openAppSettings = async () => {
[](#%5F%5Fcodelineno-10-49)  await BluetoothLowEnergy.openAppSettings();
[](#%5F%5Fcodelineno-10-50)};
[](#%5F%5Fcodelineno-10-51)
[](#%5F%5Fcodelineno-10-52)const openBluetoothSettings = async () => {
[](#%5F%5Fcodelineno-10-53)  await BluetoothLowEnergy.openBluetoothSettings();
[](#%5F%5Fcodelineno-10-54)};
[](#%5F%5Fcodelineno-10-55)
[](#%5F%5Fcodelineno-10-56)const openLocationSettings = async () => {
[](#%5F%5Fcodelineno-10-57)  await BluetoothLowEnergy.openLocationSettings();
[](#%5F%5Fcodelineno-10-58)};
[](#%5F%5Fcodelineno-10-59)
[](#%5F%5Fcodelineno-10-60)const readCharacteristic = async () => {
[](#%5F%5Fcodelineno-10-61)  const result = await BluetoothLowEnergy.readCharacteristic({
[](#%5F%5Fcodelineno-10-62)    characteristicId: '00002a00-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-63)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-64)    serviceId: '00001800-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-65)  });
[](#%5F%5Fcodelineno-10-66)  return result.value;
[](#%5F%5Fcodelineno-10-67)};
[](#%5F%5Fcodelineno-10-68)
[](#%5F%5Fcodelineno-10-69)const readDescriptor = async () => {
[](#%5F%5Fcodelineno-10-70)  const result = await BluetoothLowEnergy.readDescriptor({
[](#%5F%5Fcodelineno-10-71)    characteristicId: '00002a00-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-72)    descriptorId: '00002902-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-73)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-74)    serviceId: '00001800-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-75)  });
[](#%5F%5Fcodelineno-10-76)  return result.value;
[](#%5F%5Fcodelineno-10-77)};
[](#%5F%5Fcodelineno-10-78)
[](#%5F%5Fcodelineno-10-79)const readRssi = async () => {
[](#%5F%5Fcodelineno-10-80)  const result = await BluetoothLowEnergy.readRssi({ deviceId: '00:00:00:00:00:00' });
[](#%5F%5Fcodelineno-10-81)  return result.rssi;
[](#%5F%5Fcodelineno-10-82)};
[](#%5F%5Fcodelineno-10-83)
[](#%5F%5Fcodelineno-10-84)const requestConnectionPriority = async () => {
[](#%5F%5Fcodelineno-10-85)  await BluetoothLowEnergy.requestConnectionPriority({
[](#%5F%5Fcodelineno-10-86)    connectionPriority: ConnectionPriority.BALANCED,
[](#%5F%5Fcodelineno-10-87)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-88)  });
[](#%5F%5Fcodelineno-10-89)};
[](#%5F%5Fcodelineno-10-90)
[](#%5F%5Fcodelineno-10-91)const requestMtu = async () => {
[](#%5F%5Fcodelineno-10-92)  await BluetoothLowEnergy.requestMtu({
[](#%5F%5Fcodelineno-10-93)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-94)    mtu: 512,
[](#%5F%5Fcodelineno-10-95)  });
[](#%5F%5Fcodelineno-10-96)};
[](#%5F%5Fcodelineno-10-97)
[](#%5F%5Fcodelineno-10-98)const setCharacteristicValue = async () => {
[](#%5F%5Fcodelineno-10-99)  await BluetoothLowEnergy.setCharacteristicValue({
[](#%5F%5Fcodelineno-10-100)    characteristicId: '00002a00-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-101)    serviceId: '00001800-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-102)    value: [1, 2, 3],
[](#%5F%5Fcodelineno-10-103)  });
[](#%5F%5Fcodelineno-10-104)};
[](#%5F%5Fcodelineno-10-105)
[](#%5F%5Fcodelineno-10-106)const startAdvertising = async () => {
[](#%5F%5Fcodelineno-10-107)  await BluetoothLowEnergy.startAdvertising({
[](#%5F%5Fcodelineno-10-108)    manufacturerData: {
[](#%5F%5Fcodelineno-10-109)      0xffff: [1, 2, 3]
[](#%5F%5Fcodelineno-10-110)    },
[](#%5F%5Fcodelineno-10-111)    name: 'MyDevice',
[](#%5F%5Fcodelineno-10-112)    services: [
[](#%5F%5Fcodelineno-10-113)      {
[](#%5F%5Fcodelineno-10-114)        id: '0000180A-0000-1000-8000-00805F9B34FB',
[](#%5F%5Fcodelineno-10-115)        characteristics: [
[](#%5F%5Fcodelineno-10-116)          {
[](#%5F%5Fcodelineno-10-117)            id: '00002A29-0000-1000-8000-00805F9B34FB',
[](#%5F%5Fcodelineno-10-118)            descriptors: [], // Descriptors are ignored for now
[](#%5F%5Fcodelineno-10-119)            permissions: {
[](#%5F%5Fcodelineno-10-120)              read: true,
[](#%5F%5Fcodelineno-10-121)              write: true,
[](#%5F%5Fcodelineno-10-122)            },
[](#%5F%5Fcodelineno-10-123)            properties: {
[](#%5F%5Fcodelineno-10-124)              read: true,
[](#%5F%5Fcodelineno-10-125)              write: true,
[](#%5F%5Fcodelineno-10-126)              notify: true,
[](#%5F%5Fcodelineno-10-127)              indicate: true,
[](#%5F%5Fcodelineno-10-128)            },
[](#%5F%5Fcodelineno-10-129)          },
[](#%5F%5Fcodelineno-10-130)        ],
[](#%5F%5Fcodelineno-10-131)      },
[](#%5F%5Fcodelineno-10-132)    ],
[](#%5F%5Fcodelineno-10-133)  });
[](#%5F%5Fcodelineno-10-134)};
[](#%5F%5Fcodelineno-10-135)
[](#%5F%5Fcodelineno-10-136)const startCharacteristicNotifications = async () => {
[](#%5F%5Fcodelineno-10-137)  await BluetoothLowEnergy.startCharacteristicNotifications({
[](#%5F%5Fcodelineno-10-138)    characteristicId: '00002a00-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-139)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-140)    serviceId: '00001800-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-141)  });
[](#%5F%5Fcodelineno-10-142)};
[](#%5F%5Fcodelineno-10-143)
[](#%5F%5Fcodelineno-10-144)const startForegroundService = async () => {
[](#%5F%5Fcodelineno-10-145)  await BluetoothLowEnergy.startForegroundService({
[](#%5F%5Fcodelineno-10-146)    body: 'Body',
[](#%5F%5Fcodelineno-10-147)    id: 1,
[](#%5F%5Fcodelineno-10-148)    smallIcon: 'smallIcon',
[](#%5F%5Fcodelineno-10-149)    title: 'Title',
[](#%5F%5Fcodelineno-10-150)  });
[](#%5F%5Fcodelineno-10-151)};
[](#%5F%5Fcodelineno-10-152)
[](#%5F%5Fcodelineno-10-153)const startScan = async () => {
[](#%5F%5Fcodelineno-10-154)  await BluetoothLowEnergy.startScan();
[](#%5F%5Fcodelineno-10-155)};
[](#%5F%5Fcodelineno-10-156)
[](#%5F%5Fcodelineno-10-157)const stopAdvertising = async () => {
[](#%5F%5Fcodelineno-10-158)  await BluetoothLowEnergy.stopAdvertising();
[](#%5F%5Fcodelineno-10-159)};
[](#%5F%5Fcodelineno-10-160)
[](#%5F%5Fcodelineno-10-161)const stopCharacteristicNotifications = async () => {
[](#%5F%5Fcodelineno-10-162)  await BluetoothLowEnergy.stopCharacteristicNotifications({
[](#%5F%5Fcodelineno-10-163)    characteristicId: '00002a00-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-164)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-165)    serviceId: '00001800-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-166)  });
[](#%5F%5Fcodelineno-10-167)};
[](#%5F%5Fcodelineno-10-168)
[](#%5F%5Fcodelineno-10-169)const stopForegroundService = async () => {
[](#%5F%5Fcodelineno-10-170)  await BluetoothLowEnergy.stopForegroundService();
[](#%5F%5Fcodelineno-10-171)};
[](#%5F%5Fcodelineno-10-172)
[](#%5F%5Fcodelineno-10-173)const stopScan = async () => {
[](#%5F%5Fcodelineno-10-174)  await BluetoothLowEnergy.stopScan();
[](#%5F%5Fcodelineno-10-175)};
[](#%5F%5Fcodelineno-10-176)
[](#%5F%5Fcodelineno-10-177)const writeCharacteristic = async () => {
[](#%5F%5Fcodelineno-10-178)  await BluetoothLowEnergy.writeCharacteristic({
[](#%5F%5Fcodelineno-10-179)    characteristicId: '00002a00-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-180)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-181)    serviceId: '00001800-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-182)    value: [1, 2, 3],
[](#%5F%5Fcodelineno-10-183)  });
[](#%5F%5Fcodelineno-10-184)};
[](#%5F%5Fcodelineno-10-185)
[](#%5F%5Fcodelineno-10-186)const writeDescriptor = async () => {
[](#%5F%5Fcodelineno-10-187)  await BluetoothLowEnergy.writeDescriptor({
[](#%5F%5Fcodelineno-10-188)    characteristicId: '00002a00-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-189)    descriptorId: '00002902-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-190)    deviceId: '00:00:00:00:00:00',
[](#%5F%5Fcodelineno-10-191)    serviceId: '00001800-0000-1000-8000-00805f9b34fb',
[](#%5F%5Fcodelineno-10-192)    value: [1, 2, 3],
[](#%5F%5Fcodelineno-10-193)  });
[](#%5F%5Fcodelineno-10-194)};
[](#%5F%5Fcodelineno-10-195)
[](#%5F%5Fcodelineno-10-196)const checkPermissions = async () => {
[](#%5F%5Fcodelineno-10-197)  const result = await BluetoothLowEnergy.checkPermissions();
[](#%5F%5Fcodelineno-10-198)  return result;
[](#%5F%5Fcodelineno-10-199)};
[](#%5F%5Fcodelineno-10-200)
[](#%5F%5Fcodelineno-10-201)const requestPermissions = async () => {
[](#%5F%5Fcodelineno-10-202)  const result = await BluetoothLowEnergy.requestPermissions();
[](#%5F%5Fcodelineno-10-203)  return result;
[](#%5F%5Fcodelineno-10-204)};
[](#%5F%5Fcodelineno-10-205)
[](#%5F%5Fcodelineno-10-206)const addListener = () => {
[](#%5F%5Fcodelineno-10-207)  BluetoothLowEnergy.addListener('characteristicChanged', (event) => {
[](#%5F%5Fcodelineno-10-208)    console.log('Characteristic changed', event);
[](#%5F%5Fcodelineno-10-209)  });
[](#%5F%5Fcodelineno-10-210)
[](#%5F%5Fcodelineno-10-211)  BluetoothLowEnergy.addListener('characteristicWriteRequest', async (event) => {
[](#%5F%5Fcodelineno-10-212)    console.log('Characteristic write request', event);
[](#%5F%5Fcodelineno-10-213)  });
[](#%5F%5Fcodelineno-10-214)
[](#%5F%5Fcodelineno-10-215)  BluetoothLowEnergy.addListener('deviceConnected', (event) => {
[](#%5F%5Fcodelineno-10-216)    console.log('Device connected', event);
[](#%5F%5Fcodelineno-10-217)  });
[](#%5F%5Fcodelineno-10-218)
[](#%5F%5Fcodelineno-10-219)  BluetoothLowEnergy.addListener('deviceDisconnected', (event) => {
[](#%5F%5Fcodelineno-10-220)    console.log('Device disconnected', event);
[](#%5F%5Fcodelineno-10-221)  });
[](#%5F%5Fcodelineno-10-222)
[](#%5F%5Fcodelineno-10-223)  BluetoothLowEnergy.addListener('deviceScanned', (event) => {
[](#%5F%5Fcodelineno-10-224)    console.log('Device scanned', event);
[](#%5F%5Fcodelineno-10-225)  });
[](#%5F%5Fcodelineno-10-226)};
[](#%5F%5Fcodelineno-10-227)
[](#%5F%5Fcodelineno-10-228)const removeAllListeners = () => {
[](#%5F%5Fcodelineno-10-229)  BluetoothLowEnergy.removeAllListeners();
[](#%5F%5Fcodelineno-10-230)};
[](#%5F%5Fcodelineno-10-231)
[](#%5F%5Fcodelineno-10-232)const convertBytesToHex = (bytes: number[]) => {
[](#%5F%5Fcodelineno-10-233)  return BluetoothLowEnergyUtils.convertBytesToHex({ bytes });
[](#%5F%5Fcodelineno-10-234)};
`

## API[¶](#api "Permanent link")

* [@capawesome-team/capacitor-bluetooth-low-energy](#capawesome-teamcapacitor-bluetooth-low-energy)
* [Features](#features)
* [Testimonials](#testimonials)
* [Compatibility](#compatibility)
* [Demo](#demo)
* [Guides](#guides)
* [Installation](#installation)  
   * [Android](#android)  
   * [Features](#features-1)  
   * [Permissions](#permissions)  
   * [Services](#services)  
   * [Headless Task](#headless-task)  
   * [Proguard](#proguard)  
   * [iOS](#ios)  
   * [Privacy Descriptions](#privacy-descriptions)  
   * [Capabilities](#capabilities)
* [Configuration](#configuration)
* [Usage](#usage)
* [API](#api)  
   * [connect(...)](#connect)  
   * [createBond(...)](#createbond)  
   * [disconnect(...)](#disconnect)  
   * [discoverServices(...)](#discoverservices)  
   * [getConnectedDevices()](#getconnecteddevices)  
   * [getServices(...)](#getservices)  
   * [initialize(...)](#initialize)  
   * [isAvailable()](#isavailable)  
   * [isBonded(...)](#isbonded)  
   * [isEnabled()](#isenabled)  
   * [isLocationEnabled()](#islocationenabled)  
   * [openAppSettings()](#openappsettings)  
   * [openBluetoothSettings()](#openbluetoothsettings)  
   * [openLocationSettings()](#openlocationsettings)  
   * [readCharacteristic(...)](#readcharacteristic)  
   * [readDescriptor(...)](#readdescriptor)  
   * [readRssi(...)](#readrssi)  
   * [requestConnectionPriority(...)](#requestconnectionpriority)  
   * [requestMtu(...)](#requestmtu)  
   * [setCharacteristicValue(...)](#setcharacteristicvalue)  
   * [startAdvertising(...)](#startadvertising)  
   * [startCharacteristicNotifications(...)](#startcharacteristicnotifications)  
   * [startForegroundService(...)](#startforegroundservice)  
   * [startScan(...)](#startscan)  
   * [stopAdvertising()](#stopadvertising)  
   * [stopCharacteristicNotifications(...)](#stopcharacteristicnotifications)  
   * [stopForegroundService()](#stopforegroundservice)  
   * [stopScan()](#stopscan)  
   * [writeCharacteristic(...)](#writecharacteristic)  
   * [writeDescriptor(...)](#writedescriptor)  
   * [checkPermissions()](#checkpermissions)  
   * [requestPermissions(...)](#requestpermissions)  
   * [addListener('characteristicChanged', ...)](#addlistenercharacteristicchanged-)  
   * [addListener('characteristicWriteRequest', ...)](#addlistenercharacteristicwriterequest-)  
   * [addListener('deviceConnected', ...)](#addlistenerdeviceconnected-)  
   * [addListener('deviceDisconnected', ...)](#addlistenerdevicedisconnected-)  
   * [addListener('deviceScanned', ...)](#addlistenerdevicescanned-)  
   * [removeAllListeners()](#removealllisteners)  
   * [Interfaces](#interfaces)  
   * [ConnectOptions](#connectoptions)  
   * [CreateBondOptions](#createbondoptions)  
   * [DisconnectOptions](#disconnectoptions)  
   * [DiscoverServiceOptions](#discoverserviceoptions)  
   * [GetConnectedDevicesResult](#getconnecteddevicesresult)  
   * [Device](#device)  
   * [GetServicesResult](#getservicesresult)  
   * [Service](#service)  
   * [Characteristic](#characteristic)  
   * [Descriptor](#descriptor)  
   * [CharacteristicPermissions](#characteristicpermissions)  
   * [CharacteristicProperties](#characteristicproperties)  
   * [GetServicesOptions](#getservicesoptions)  
   * [InitializeOptions](#initializeoptions)  
   * [IsAvailableResult](#isavailableresult)  
   * [IsBondedResult](#isbondedresult)  
   * [IsBondedOptions](#isbondedoptions)  
   * [IsEnabledResult](#isenabledresult)  
   * [IsLocationEnabledResult](#islocationenabledresult)  
   * [ReadCharacteristicResult](#readcharacteristicresult)  
   * [ReadCharacteristicOptions](#readcharacteristicoptions)  
   * [ReadDescriptorResult](#readdescriptorresult)  
   * [ReadDescriptorOptions](#readdescriptoroptions)  
   * [ReadRssiResult](#readrssiresult)  
   * [ReadRssiOptions](#readrssioptions)  
   * [RequestConnectionPriorityOptions](#requestconnectionpriorityoptions)  
   * [RequestMtuOptions](#requestmtuoptions)  
   * [SetCharacteristicValueOptions](#setcharacteristicvalueoptions)  
   * [StartAdvertisingOptions](#startadvertisingoptions)  
   * [StartCharacteristicNotificationsOptions](#startcharacteristicnotificationsoptions)  
   * [StartForegroundServiceOptions](#startforegroundserviceoptions)  
   * [StartScanOptions](#startscanoptions)  
   * [StopCharacteristicNotificationsOptions](#stopcharacteristicnotificationsoptions)  
   * [WriteCharacteristicOptions](#writecharacteristicoptions)  
   * [WriteDescriptorOptions](#writedescriptoroptions)  
   * [PermissionStatus](#permissionstatus)  
   * [BluetoothLowEnergyPluginPermission](#bluetoothlowenergypluginpermission)  
   * [PluginListenerHandle](#pluginlistenerhandle)  
   * [CharacteristicChangedEvent](#characteristicchangedevent)  
   * [CharacteristicWriteRequestEvent](#characteristicwriterequestevent)  
   * [DeviceConnectedEvent](#deviceconnectedevent)  
   * [DeviceDisconnectedEvent](#devicedisconnectedevent)  
   * [DeviceScannedEvent](#devicescannedevent)  
   * [Type Aliases](#type-aliases)  
   * [PermissionState](#permissionstate)  
   * [BluetoothLowEnergyPermissionType](#bluetoothlowenergypermissiontype)  
   * [Enums](#enums)  
   * [ConnectionPriority](#connectionpriority)
* [Utils](#utils)
* [Changelog](#changelog)
* [Breaking Changes](#breaking-changes)
* [License](#license)

### connect(...)[¶](#connect "Permanent link")

`[](#%5F%5Fcodelineno-11-1)connect(options: ConnectOptions) => Promise<void>
`

Connect to a BLE device.

Only available on Android and iOS.

| Param       | Type                              |
| ----------- | --------------------------------- |
| **options** | [ConnectOptions](#connectoptions) |

**Since:** 6.0.0

---

### createBond(...)[¶](#createbond "Permanent link")

`[](#%5F%5Fcodelineno-12-1)createBond(options: CreateBondOptions) => Promise<void>
`

Create a bond with the BLE device.

Only available on Android.

| Param       | Type                                    |
| ----------- | --------------------------------------- |
| **options** | [CreateBondOptions](#createbondoptions) |

**Since:** 6.0.0

---

### disconnect(...)[¶](#disconnect "Permanent link")

`[](#%5F%5Fcodelineno-13-1)disconnect(options: DisconnectOptions) => Promise<void>
`

Disconnect from the BLE device.

Only available on Android and iOS.

| Param       | Type                                    |
| ----------- | --------------------------------------- |
| **options** | [DisconnectOptions](#disconnectoptions) |

**Since:** 6.0.0

---

### discoverServices(...)[¶](#discoverservices "Permanent link")

`[](#%5F%5Fcodelineno-14-1)discoverServices(options: DiscoverServiceOptions) => Promise<void>
`

Discover services provided by the device.

On **iOS**, this operation may take up to 30 seconds.

Only available on Android and iOS.

| Param       | Type                                              |
| ----------- | ------------------------------------------------- |
| **options** | [DiscoverServiceOptions](#discoverserviceoptions) |

**Since:** 6.0.0

---

### getConnectedDevices()[¶](#getconnecteddevices "Permanent link")

`[](#%5F%5Fcodelineno-15-1)getConnectedDevices() => Promise<GetConnectedDevicesResult>
`

Get a list of connected devices.

Only available on Android and iOS.

**Returns:** `Promise<[GetConnectedDevicesResult](#getconnecteddevicesresult)>`

**Since:** 6.0.0

---

### getServices(...)[¶](#getservices "Permanent link")

`[](#%5F%5Fcodelineno-16-1)getServices(options: GetServicesOptions) => Promise<GetServicesResult>
`

Get a list of services provided by the device.

Only available on Android and iOS.

| Param       | Type                                      |
| ----------- | ----------------------------------------- |
| **options** | [GetServicesOptions](#getservicesoptions) |

**Returns:** `Promise<[GetServicesResult](#getservicesresult)>`

**Since:** 6.0.0

---

### initialize(...)[¶](#initialize "Permanent link")

`[](#%5F%5Fcodelineno-17-1)initialize(options?: InitializeOptions | undefined) => Promise<void>
`

Initialize the plugin. This method must be called before any other method.

On **iOS**, this will prompt the user for Bluetooth permissions. On **Android** and **Web**, this does nothing.

| Param       | Type                                    |
| ----------- | --------------------------------------- |
| **options** | [InitializeOptions](#initializeoptions) |

**Since:** 6.0.0

---

### isAvailable()[¶](#isavailable "Permanent link")

`[](#%5F%5Fcodelineno-18-1)isAvailable() => Promise<IsAvailableResult>
`

Check whether or not Bluetooth Low Energy is available on the device.

**Returns:** `Promise<[IsAvailableResult](#isavailableresult)>`

**Since:** 7.3.0

---

### isBonded(...)[¶](#isbonded "Permanent link")

`[](#%5F%5Fcodelineno-19-1)isBonded(options: IsBondedOptions) => Promise<IsBondedResult>
`

Check if the device is bonded.

Only available on Android.

| Param       | Type                                |
| ----------- | ----------------------------------- |
| **options** | [IsBondedOptions](#isbondedoptions) |

**Returns:** `Promise<[IsBondedResult](#isbondedresult)>`

**Since:** 6.0.0

---

### isEnabled()[¶](#isenabled "Permanent link")

`[](#%5F%5Fcodelineno-20-1)isEnabled() => Promise<IsEnabledResult>
`

Check if Bluetooth is enabled.

On **iOS**, requires the plugin to be initialized. Returns `false` if not initialized.

Only available on Android and iOS.

**Returns:** `Promise<[IsEnabledResult](#isenabledresult)>`

**Since:** 6.0.0

---

### isLocationEnabled()[¶](#islocationenabled "Permanent link")

`[](#%5F%5Fcodelineno-21-1)isLocationEnabled() => Promise<IsLocationEnabledResult>
`

Check if location services are enabled.

Only available on Android.

**Returns:** `Promise<[IsLocationEnabledResult](#islocationenabledresult)>`

**Since:** 7.7.0

---

### openAppSettings()[¶](#openappsettings "Permanent link")

`[](#%5F%5Fcodelineno-22-1)openAppSettings() => Promise<void>
`

Open the Bluetooth settings on the device.

Only available on Android and iOS.

**Since:** 6.0.0

---

### openBluetoothSettings()[¶](#openbluetoothsettings "Permanent link")

`[](#%5F%5Fcodelineno-23-1)openBluetoothSettings() => Promise<void>
`

Open the Bluetooth settings on the device.

Only available on Android.

**Since:** 6.0.0

---

### openLocationSettings()[¶](#openlocationsettings "Permanent link")

`[](#%5F%5Fcodelineno-24-1)openLocationSettings() => Promise<void>
`

Open the location settings on the device.

Only available on Android.

**Since:** 6.0.0

---

### readCharacteristic(...)[¶](#readcharacteristic "Permanent link")

`[](#%5F%5Fcodelineno-25-1)readCharacteristic(options: ReadCharacteristicOptions) => Promise<ReadCharacteristicResult>
`

Read the value of a characteristic.

Only available on Android and iOS.

| Param       | Type                                                    |
| ----------- | ------------------------------------------------------- |
| **options** | [ReadCharacteristicOptions](#readcharacteristicoptions) |

**Returns:** `Promise<[ReadCharacteristicResult](#readcharacteristicresult)>`

**Since:** 6.0.0

---

### readDescriptor(...)[¶](#readdescriptor "Permanent link")

`[](#%5F%5Fcodelineno-26-1)readDescriptor(options: ReadDescriptorOptions) => Promise<ReadDescriptorResult>
`

Read the value of a descriptor.

Only available on Android and iOS.

| Param       | Type                                            |
| ----------- | ----------------------------------------------- |
| **options** | [ReadDescriptorOptions](#readdescriptoroptions) |

**Returns:** `Promise<[ReadDescriptorResult](#readdescriptorresult)>`

**Since:** 6.0.0

---

### readRssi(...)[¶](#readrssi "Permanent link")

`[](#%5F%5Fcodelineno-27-1)readRssi(options: ReadRssiOptions) => Promise<ReadRssiResult>
`

Read the RSSI value of the device.

Only available on Android and iOS.

| Param       | Type                                |
| ----------- | ----------------------------------- |
| **options** | [ReadRssiOptions](#readrssioptions) |

**Returns:** `Promise<[ReadRssiResult](#readrssiresult)>`

**Since:** 6.0.0

---

### requestConnectionPriority(...)[¶](#requestconnectionpriority "Permanent link")

`[](#%5F%5Fcodelineno-28-1)requestConnectionPriority(options: RequestConnectionPriorityOptions) => Promise<void>
`

Request a connection priority.

Only available on Android.

| Param       | Type                                                                  |
| ----------- | --------------------------------------------------------------------- |
| **options** | [RequestConnectionPriorityOptions](#requestconnectionpriorityoptions) |

**Since:** 6.0.0

---

### requestMtu(...)[¶](#requestmtu "Permanent link")

`[](#%5F%5Fcodelineno-29-1)requestMtu(options: RequestMtuOptions) => Promise<void>
`

Request an MTU size.

Only available on Android.

| Param       | Type                                    |
| ----------- | --------------------------------------- |
| **options** | [RequestMtuOptions](#requestmtuoptions) |

**Since:** 6.0.0

---

### setCharacteristicValue(...)[¶](#setcharacteristicvalue "Permanent link")

`[](#%5F%5Fcodelineno-30-1)setCharacteristicValue(options: SetCharacteristicValueOptions) => Promise<void>
`

Set the value of a characteristic.

Only available on Android.

| Param       | Type                                                            |
| ----------- | --------------------------------------------------------------- |
| **options** | [SetCharacteristicValueOptions](#setcharacteristicvalueoptions) |

**Since:** 7.2.0

---

### startAdvertising(...)[¶](#startadvertising "Permanent link")

`[](#%5F%5Fcodelineno-31-1)startAdvertising(options: StartAdvertisingOptions) => Promise<void>
`

Start advertising as a BLE device.

Only available on Android and iOS.

| Param       | Type                                                |
| ----------- | --------------------------------------------------- |
| **options** | [StartAdvertisingOptions](#startadvertisingoptions) |

**Since:** 7.2.0

---

### startCharacteristicNotifications(...)[¶](#startcharacteristicnotifications "Permanent link")

`[](#%5F%5Fcodelineno-32-1)startCharacteristicNotifications(options: StartCharacteristicNotificationsOptions) => Promise<void>
`

Start listening for characteristic value changes. This will emit the `characteristicChanged` event when a value changes.

Only available on Android and iOS.

| Param       | Type                                                                                |
| ----------- | ----------------------------------------------------------------------------------- |
| **options** | [StartCharacteristicNotificationsOptions](#startcharacteristicnotificationsoptions) |

**Since:** 6.0.0

---

### startForegroundService(...)[¶](#startforegroundservice "Permanent link")

`[](#%5F%5Fcodelineno-33-1)startForegroundService(options?: StartForegroundServiceOptions | undefined) => Promise<void>
`

Start the foreground service and show a notification.

This method should be called when the app is moved to the background to keep the Bluetooth connections alive.

Only available on Android.

| Param       | Type                                                            |
| ----------- | --------------------------------------------------------------- |
| **options** | [StartForegroundServiceOptions](#startforegroundserviceoptions) |

**Since:** 6.0.0

---

### startScan(...)[¶](#startscan "Permanent link")

`[](#%5F%5Fcodelineno-34-1)startScan(options?: StartScanOptions | undefined) => Promise<void>
`

Start scanning for BLE devices. This will emit the `deviceScanned` event when a device is found.

Only available on Android and iOS.

| Param       | Type                                  |
| ----------- | ------------------------------------- |
| **options** | [StartScanOptions](#startscanoptions) |

**Since:** 6.0.0

---

### stopAdvertising()[¶](#stopadvertising "Permanent link")

`[](#%5F%5Fcodelineno-35-1)stopAdvertising() => Promise<void>
`

Stop advertising as a BLE device.

Only available on Android and iOS.

**Since:** 7.2.0

---

### stopCharacteristicNotifications(...)[¶](#stopcharacteristicnotifications "Permanent link")

`[](#%5F%5Fcodelineno-36-1)stopCharacteristicNotifications(options: StopCharacteristicNotificationsOptions) => Promise<void>
`

Stop listening for characteristic value changes.

Only available on Android and iOS.

| Param       | Type                                                                              |
| ----------- | --------------------------------------------------------------------------------- |
| **options** | [StopCharacteristicNotificationsOptions](#stopcharacteristicnotificationsoptions) |

**Since:** 6.0.0

---

### stopForegroundService()[¶](#stopforegroundservice "Permanent link")

`[](#%5F%5Fcodelineno-37-1)stopForegroundService() => Promise<void>
`

Stop the foreground service and remove the notification.

This method should be called when the app is moved to the foreground since the foreground service is no longer needed.

Only available on Android.

**Since:** 6.0.0

---

### stopScan()[¶](#stopscan "Permanent link")

`[](#%5F%5Fcodelineno-38-1)stopScan() => Promise<void>
`

Stop scanning for BLE devices.

Only available on Android and iOS.

**Since:** 6.0.0

---

### writeCharacteristic(...)[¶](#writecharacteristic "Permanent link")

`[](#%5F%5Fcodelineno-39-1)writeCharacteristic(options: WriteCharacteristicOptions) => Promise<void>
`

Write a value to a characteristic.

Only available on Android and iOS.

| Param       | Type                                                      |
| ----------- | --------------------------------------------------------- |
| **options** | [WriteCharacteristicOptions](#writecharacteristicoptions) |

**Since:** 6.0.0

---

### writeDescriptor(...)[¶](#writedescriptor "Permanent link")

`[](#%5F%5Fcodelineno-40-1)writeDescriptor(options: WriteDescriptorOptions) => Promise<void>
`

Write a value to a descriptor.

Only available on Android and iOS.

| Param       | Type                                              |
| ----------- | ------------------------------------------------- |
| **options** | [WriteDescriptorOptions](#writedescriptoroptions) |

**Since:** 6.0.0

---

### checkPermissions()[¶](#checkpermissions "Permanent link")

`[](#%5F%5Fcodelineno-41-1)checkPermissions() => Promise<PermissionStatus>
`

Check permissions for the plugin.

Only available on Android.

**Returns:** `Promise<[PermissionStatus](#permissionstatus)>`

**Since:** 6.0.0

---

### requestPermissions(...)[¶](#requestpermissions "Permanent link")

`[](#%5F%5Fcodelineno-42-1)requestPermissions(permissions?: BluetoothLowEnergyPluginPermission | undefined) => Promise<PermissionStatus>
`

Request permissions for the plugin.

Only available on Android.

| Param           | Type                                                                      |
| --------------- | ------------------------------------------------------------------------- |
| **permissions** | [BluetoothLowEnergyPluginPermission](#bluetoothlowenergypluginpermission) |

**Returns:** `Promise<[PermissionStatus](#permissionstatus)>`

**Since:** 6.0.0

---

### addListener('characteristicChanged', ...)[¶](#addlistenercharacteristicchanged "Permanent link")

`[](#%5F%5Fcodelineno-43-1)addListener(eventName: 'characteristicChanged', listenerFunc: (event: CharacteristicChangedEvent) => void) => Promise<PluginListenerHandle>
`

Called when a characteristic value changes.

Only available on Android and iOS.

| Param            | Type                                                                       |
| ---------------- | -------------------------------------------------------------------------- |
| **eventName**    | 'characteristicChanged'                                                    |
| **listenerFunc** | (event: [CharacteristicChangedEvent](#characteristicchangedevent)) => void |

**Returns:** `Promise<[PluginListenerHandle](#pluginlistenerhandle)>`

**Since:** 6.0.0

---

### addListener('characteristicWriteRequest', ...)[¶](#addlistenercharacteristicwriterequest "Permanent link")

`[](#%5F%5Fcodelineno-44-1)addListener(eventName: 'characteristicWriteRequest', listenerFunc: (event: CharacteristicWriteRequestEvent) => void) => Promise<PluginListenerHandle>
`

Called when a characteristic write request is received.

Only available on Android.

| Param            | Type                                                                                 |
| ---------------- | ------------------------------------------------------------------------------------ |
| **eventName**    | 'characteristicWriteRequest'                                                         |
| **listenerFunc** | (event: [CharacteristicWriteRequestEvent](#characteristicwriterequestevent)) => void |

**Returns:** `Promise<[PluginListenerHandle](#pluginlistenerhandle)>`

**Since:** 7.2.0

---

### addListener('deviceConnected', ...)[¶](#addlistenerdeviceconnected "Permanent link")

`[](#%5F%5Fcodelineno-45-1)addListener(eventName: 'deviceConnected', listenerFunc: (event: DeviceConnectedEvent) => void) => Promise<PluginListenerHandle>
`

Called when a device is connected.

Only available on Android and iOS.

| Param            | Type                                                           |
| ---------------- | -------------------------------------------------------------- |
| **eventName**    | 'deviceConnected'                                              |
| **listenerFunc** | (event: [DeviceConnectedEvent](#deviceconnectedevent)) => void |

**Returns:** `Promise<[PluginListenerHandle](#pluginlistenerhandle)>`

**Since:** 7.1.0

---

### addListener('deviceDisconnected', ...)[¶](#addlistenerdevicedisconnected "Permanent link")

`[](#%5F%5Fcodelineno-46-1)addListener(eventName: 'deviceDisconnected', listenerFunc: (event: DeviceDisconnectedEvent) => void) => Promise<PluginListenerHandle>
`

Called when a device is disconnected.

Only available on Android and iOS.

| Param            | Type                                                                 |
| ---------------- | -------------------------------------------------------------------- |
| **eventName**    | 'deviceDisconnected'                                                 |
| **listenerFunc** | (event: [DeviceDisconnectedEvent](#devicedisconnectedevent)) => void |

**Returns:** `Promise<[PluginListenerHandle](#pluginlistenerhandle)>`

**Since:** 6.0.0

---

### addListener('deviceScanned', ...)[¶](#addlistenerdevicescanned "Permanent link")

`[](#%5F%5Fcodelineno-47-1)addListener(eventName: 'deviceScanned', listenerFunc: (event: DeviceScannedEvent) => void) => Promise<PluginListenerHandle>
`

Called when an error occurs during the scan session.

Only available on Android and iOS.

| Param            | Type                                                       |
| ---------------- | ---------------------------------------------------------- |
| **eventName**    | 'deviceScanned'                                            |
| **listenerFunc** | (event: [DeviceScannedEvent](#devicescannedevent)) => void |

**Returns:** `Promise<[PluginListenerHandle](#pluginlistenerhandle)>`

**Since:** 6.0.0

---

### removeAllListeners()[¶](#removealllisteners "Permanent link")

`[](#%5F%5Fcodelineno-48-1)removeAllListeners() => Promise<void>
`

Remove all listeners for this plugin.

**Since:** 6.0.0

---

### Interfaces[¶](#interfaces "Permanent link")

#### ConnectOptions[¶](#connectoptions "Permanent link")

| Prop              | Type    | Description                                                                                                                                                            | Default | Since |
| ----------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **autoConnect**   | boolean | Whether to directly connect to the remote device (false) or to automatically connect as soon as the remote device becomes available (true). Only available on Android. | false   | 7.1.0 |
| **autoReconnect** | boolean | Whether to enable automatic reconnection to the peripheral when the connection is lost. Only available on Android and iOS (17.0+).                                     | false   | 7.6.0 |
| **deviceId**      | string  | The address of the device to connect to.                                                                                                                               | 6.0.0   |       |
| **timeout**       | number  | The timeout for the connect operation in milliseconds. If the operation takes longer than this value, the promise will be rejected.                                    | 10000   | 6.0.0 |

#### CreateBondOptions[¶](#createbondoptions "Permanent link")

| Prop         | Type   | Description                                                                                                                             | Default | Since |
| ------------ | ------ | --------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **deviceId** | string | The address of the device to create a bond with.                                                                                        | 6.0.0   |       |
| **timeout**  | number | The timeout for the create bond operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 10000   | 6.0.0 |

#### DisconnectOptions[¶](#disconnectoptions "Permanent link")

| Prop         | Type   | Description                                                                                                                            | Default | Since |
| ------------ | ------ | -------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **deviceId** | string | The address of the device to disconnect from.                                                                                          | 6.0.0   |       |
| **timeout**  | number | The timeout for the disconnect operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |

#### DiscoverServiceOptions[¶](#discoverserviceoptions "Permanent link")

| Prop         | Type   | Description                                                                                                                                   | Default | Since |
| ------------ | ------ | --------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **deviceId** | string | The address of the device to discover services for.                                                                                           | 6.0.0   |       |
| **timeout**  | number | The timeout for the discover services operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 20000   | 6.0.0 |

#### GetConnectedDevicesResult[¶](#getconnecteddevicesresult "Permanent link")

| Prop        | Type       | Description                    | Since |
| ----------- | ---------- | ------------------------------ | ----- |
| **devices** | Device\[\] | An array of connected devices. | 6.0.0 |

#### Device[¶](#device "Permanent link")

| Prop     | Type   | Description                       | Since |
| -------- | ------ | --------------------------------- | ----- |
| **id**   | string | The UUID of the connected device. | 6.0.0 |
| **name** | string | The name of the connected device. | 6.0.0 |

#### GetServicesResult[¶](#getservicesresult "Permanent link")

| Prop         | Type        | Description                                  | Since |
| ------------ | ----------- | -------------------------------------------- | ----- |
| **services** | Service\[\] | An array of services provided by the device. | 6.0.0 |

#### Service[¶](#service "Permanent link")

| Prop                | Type               | Description                         | Since |
| ------------------- | ------------------ | ----------------------------------- | ----- |
| **id**              | string             | The UUID of the service.            | 6.0.0 |
| **characteristics** | Characteristic\[\] | The characteristics of the service. | 6.0.0 |

#### Characteristic[¶](#characteristic "Permanent link")

| Prop            | Type                                                    | Description                                                                                                            | Since |
| --------------- | ------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ----- |
| **id**          | string                                                  | The UUID of the characteristic.                                                                                        | 6.0.0 |
| **descriptors** | Descriptor\[\]                                          | The descriptors of the characteristic. **Note**: This property is currently ignored when advertising a characteristic. | 6.0.0 |
| **permissions** | [CharacteristicPermissions](#characteristicpermissions) | The permissions of the characteristic. Only available on Android.                                                      | 7.2.0 |
| **properties**  | [CharacteristicProperties](#characteristicproperties)   | The properties of the characteristic.                                                                                  | 6.0.0 |

#### Descriptor[¶](#descriptor "Permanent link")

| Prop   | Type   | Description                 | Since |
| ------ | ------ | --------------------------- | ----- |
| **id** | string | The UUID of the descriptor. | 6.0.0 |

#### CharacteristicPermissions[¶](#characteristicpermissions "Permanent link")

| Prop                   | Type    | Description                                                                                                      | Since |
| ---------------------- | ------- | ---------------------------------------------------------------------------------------------------------------- | ----- |
| **read**               | boolean | Whether or not the characteristic can be read.                                                                   | 7.2.0 |
| **readEncrypted**      | boolean | Whether or not the characteristic can be read with encryption.                                                   | 7.2.0 |
| **readEncryptedMitm**  | boolean | Whether or not the characteristic can be read with encryption and MITM protection. Only available on Android.    | 7.2.0 |
| **write**              | boolean | Whether or not the characteristic can be written.                                                                | 7.2.0 |
| **writeEncrypted**     | boolean | Whether or not the characteristic can be written with encryption.                                                | 7.2.0 |
| **writeEncryptedMitm** | boolean | Whether or not the characteristic can be written with encryption and MITM protection. Only available on Android. | 7.2.0 |
| **writeSigned**        | boolean | Whether or not the characteristic can be written signed. Only available on Android.                              | 7.2.0 |
| **writeSignedMitm**    | boolean | Whether or not the characteristic can be written signed with encryption. Only available on Android.              | 7.2.0 |

#### CharacteristicProperties[¶](#characteristicproperties "Permanent link")

| Prop                           | Type    | Description                                                        | Since |
| ------------------------------ | ------- | ------------------------------------------------------------------ | ----- |
| **broadcast**                  | boolean | Whether or not the characteristic can be broadcast.                | 6.0.0 |
| **read**                       | boolean | Whether or not the characteristic can be read.                     | 6.0.0 |
| **writeWithoutResponse**       | boolean | Whether or not the characteristic can be written without response. | 6.0.0 |
| **write**                      | boolean | Whether or not the characteristic can be written.                  | 6.0.0 |
| **notify**                     | boolean | Whether or not the characteristic supports notifications.          | 6.0.0 |
| **indicate**                   | boolean | Whether or not the characteristic supports indications.            | 6.0.0 |
| **authenticatedSignedWrites**  | boolean | Whether or not the characteristic supports signed writes.          | 6.0.0 |
| **extendedProperties**         | boolean | Whether or not the characteristic supports extended properties.    | 6.0.0 |
| **notifyEncryptionRequired**   | boolean | Whether or not the characteristic supports reliable writes.        | 6.0.0 |
| **indicateEncryptionRequired** | boolean | Whether or not the characteristic supports writable auxiliaries.   | 6.0.0 |

#### GetServicesOptions[¶](#getservicesoptions "Permanent link")

| Prop         | Type   | Description                                                                                                                              | Default | Since |
| ------------ | ------ | ---------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **deviceId** | string | The address of the device to get the services for.                                                                                       | 6.0.0   |       |
| **timeout**  | number | The timeout for the get services operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |

#### InitializeOptions[¶](#initializeoptions "Permanent link")

| Prop     | Type                      | Description                                                         | Default   | Since |
| -------- | ------------------------- | ------------------------------------------------------------------- | --------- | ----- |
| **mode** | 'central' \| 'peripheral' | The mode of the Bluetooth Low Energy plugin. Only available on iOS. | 'central' | 7.2.0 |

#### IsAvailableResult[¶](#isavailableresult "Permanent link")

| Prop            | Type    | Description                                                     | Since |
| --------------- | ------- | --------------------------------------------------------------- | ----- |
| **isAvailable** | boolean | Whether or not Bluetooth Low Energy is available on the device. | 7.3.0 |

#### IsBondedResult[¶](#isbondedresult "Permanent link")

| Prop       | Type    | Description                          | Since |
| ---------- | ------- | ------------------------------------ | ----- |
| **bonded** | boolean | Whether or not the device is bonded. | 6.0.0 |

#### IsBondedOptions[¶](#isbondedoptions "Permanent link")

| Prop         | Type   | Description                                                                                                                           | Since |
| ------------ | ------ | ------------------------------------------------------------------------------------------------------------------------------------- | ----- |
| **deviceId** | string | The address of the device to check if it is bonded.                                                                                   | 6.0.0 |
| **timeout**  | number | The timeout for the is bonded operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 6.0.0 |

#### IsEnabledResult[¶](#isenabledresult "Permanent link")

| Prop        | Type    | Description                          | Since |
| ----------- | ------- | ------------------------------------ | ----- |
| **enabled** | boolean | Whether or not Bluetooth is enabled. | 6.0.0 |

#### IsLocationEnabledResult[¶](#islocationenabledresult "Permanent link")

| Prop        | Type    | Description                                   | Since |
| ----------- | ------- | --------------------------------------------- | ----- |
| **enabled** | boolean | Whether or not location services are enabled. | 7.7.0 |

#### ReadCharacteristicResult[¶](#readcharacteristicresult "Permanent link")

| Prop      | Type       | Description                            | Since |
| --------- | ---------- | -------------------------------------- | ----- |
| **value** | number\[\] | The value bytes of the characteristic. | 6.0.0 |

#### ReadCharacteristicOptions[¶](#readcharacteristicoptions "Permanent link")

| Prop                 | Type   | Description                                                                                                                      | Default | Since |
| -------------------- | ------ | -------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **characteristicId** | string | The UUID of the characteristic to read.                                                                                          | 6.0.0   |       |
| **deviceId**         | string | The address of the device to read the characteristic from.                                                                       | 6.0.0   |       |
| **serviceId**        | string | The UUID of the service to read the characteristic from.                                                                         | 6.0.0   |       |
| **timeout**          | number | The timeout for the read operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |

#### ReadDescriptorResult[¶](#readdescriptorresult "Permanent link")

| Prop      | Type       | Description                        | Since |
| --------- | ---------- | ---------------------------------- | ----- |
| **value** | number\[\] | The value bytes of the descriptor. | 6.0.0 |

#### ReadDescriptorOptions[¶](#readdescriptoroptions "Permanent link")

| Prop                 | Type   | Description                                                                                                                      | Default | Since |
| -------------------- | ------ | -------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **characteristicId** | string | The UUID of the characteristic that the descriptor belongs to.                                                                   | 6.0.0   |       |
| **descriptorId**     | string | The UUID of the descriptor to read.                                                                                              | 6.0.0   |       |
| **deviceId**         | string | The address of the device to read the descriptor from.                                                                           | 6.0.0   |       |
| **serviceId**        | string | The UUID of the service that the descriptor belongs to.                                                                          | 6.0.0   |       |
| **timeout**          | number | The timeout for the read operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |

#### ReadRssiResult[¶](#readrssiresult "Permanent link")

| Prop     | Type   | Description     | Since |
| -------- | ------ | --------------- | ----- |
| **rssi** | number | The RSSI value. | 6.0.0 |

#### ReadRssiOptions[¶](#readrssioptions "Permanent link")

| Prop         | Type   | Description                                                                                                                           | Default | Since |
| ------------ | ------ | ------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **deviceId** | string | The address of the device to read the RSSI for.                                                                                       | 6.0.0   |       |
| **timeout**  | number | The timeout for the read RSSI operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |

#### RequestConnectionPriorityOptions[¶](#requestconnectionpriorityoptions "Permanent link")

| Prop                   | Type                                      | Description                                                                                                                                             | Since |
| ---------------------- | ----------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ----- |
| **deviceId**           | string                                    | The address of the device to request the connection priority for.                                                                                       | 6.0.0 |
| **connectionPriority** | [ConnectionPriority](#connectionpriority) | The connection priority to request.                                                                                                                     | 6.0.0 |
| **timeout**            | number                                    | The timeout for the request connection priority operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 6.0.0 |

#### RequestMtuOptions[¶](#requestmtuoptions "Permanent link")

| Prop         | Type   | Description                                                                                                                             | Since |
| ------------ | ------ | --------------------------------------------------------------------------------------------------------------------------------------- | ----- |
| **deviceId** | string | The address of the device to request the MTU size for.                                                                                  | 6.0.0 |
| **mtu**      | number | The mtu size to request.                                                                                                                | 6.0.0 |
| **timeout**  | number | The timeout for the request MTU operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 6.0.0 |

#### SetCharacteristicValueOptions[¶](#setcharacteristicvalueoptions "Permanent link")

| Prop                 | Type       | Description                                          | Since |
| -------------------- | ---------- | ---------------------------------------------------- | ----- |
| **characteristicId** | string     | The UUID of the characteristic to set the value for. | 7.2.0 |
| **serviceId**        | string     | The UUID of the service to set the value for.        | 7.2.0 |
| **value**            | number\[\] | The value bytes to set for the characteristic.       | 7.2.0 |

#### StartAdvertisingOptions[¶](#startadvertisingoptions "Permanent link")

| Prop                 | Type                             | Description                                                             | Default   | Since |
| -------------------- | -------------------------------- | ----------------------------------------------------------------------- | --------- | ----- |
| **manufacturerData** | { \[key: number\]: number\[\]; } | The manufacturer specific data to advertise. Only available on Android. | 7.5.0     |       |
| **name**             | string                           | The name of the local device to advertise. Only available on iOS.       | "Unknown" | 7.2.0 |
| **services**         | Service\[\]                      | The services to advertise.                                              | 7.2.0     |       |

#### StartCharacteristicNotificationsOptions[¶](#startcharacteristicnotificationsoptions "Permanent link")

| Prop                 | Type   | Description                                                                                                                                     | Default | Since |
| -------------------- | ------ | ----------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **characteristicId** | string | The UUID of the characteristic to start notifications for.                                                                                      | 6.0.0   |       |
| **deviceId**         | string | The address of the device to start notifications for.                                                                                           | 6.0.0   |       |
| **serviceId**        | string | The UUID of the service to start notifications for.                                                                                             | 6.0.0   |       |
| **timeout**          | number | The timeout for the start notifications operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |

#### StartForegroundServiceOptions[¶](#startforegroundserviceoptions "Permanent link")

| Prop          | Type   | Description                                                                                                                                                                                                   | Default                                                                 | Since |
| ------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----- |
| **body**      | string | The body of the notification, shown below the title.                                                                                                                                                          | "App is running in the background to keep Bluetooth connections alive." | 6.0.0 |
| **id**        | number | The notification identifier.                                                                                                                                                                                  | 105                                                                     | 6.0.0 |
| **smallIcon** | string | The status bar icon for the notification. Icons should be placed in your app's res/drawable folder. The value for this option should be the drawable resource ID, which is the filename without an extension. | 6.0.0                                                                   |       |
| **title**     | string | The title of the notification.                                                                                                                                                                                | "Bluetooth Low Energy"                                                  | 6.0.0 |

#### StartScanOptions[¶](#startscanoptions "Permanent link")

| Prop           | Type       | Description                                                                             | Since |
| -------------- | ---------- | --------------------------------------------------------------------------------------- | ----- |
| **serviceIds** | string\[\] | Find devices with services that match any of the provided UUIDs. Only available on iOS. | 6.0.0 |

#### StopCharacteristicNotificationsOptions[¶](#stopcharacteristicnotificationsoptions "Permanent link")

| Prop                 | Type   | Description                                                                                                                                    | Default | Since |
| -------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **characteristicId** | string | The UUID of the characteristic to stop notifications for.                                                                                      | 6.0.0   |       |
| **deviceId**         | string | The address of the device to stop notifications for.                                                                                           | 6.0.0   |       |
| **serviceId**        | string | The UUID of the service to stop notifications for.                                                                                             | 6.0.0   |       |
| **timeout**          | number | The timeout for the stop notifications operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |

#### WriteCharacteristicOptions[¶](#writecharacteristicoptions "Permanent link")

| Prop                 | Type                           | Description                                                                                                                       | Default   | Since |
| -------------------- | ------------------------------ | --------------------------------------------------------------------------------------------------------------------------------- | --------- | ----- |
| **characteristicId** | string                         | The UUID of the characteristic to write.                                                                                          | 6.0.0     |       |
| **deviceId**         | string                         | The address of the device to write the characteristic to.                                                                         | 6.0.0     |       |
| **serviceId**        | string                         | The UUID of the service to write the characteristic to.                                                                           | 6.0.0     |       |
| **timeout**          | number                         | The timeout for the write operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000      | 6.0.0 |
| **type**             | 'default' \| 'withoutResponse' | The type of write operation.                                                                                                      | 'default' | 6.1.0 |
| **value**            | number\[\]                     | The value bytes to write to the characteristic.                                                                                   | 6.0.0     |       |

#### WriteDescriptorOptions[¶](#writedescriptoroptions "Permanent link")

| Prop                 | Type       | Description                                                                                                                       | Default | Since |
| -------------------- | ---------- | --------------------------------------------------------------------------------------------------------------------------------- | ------- | ----- |
| **characteristicId** | string     | The UUID of the characteristic that the descriptor belongs to.                                                                    | 6.0.0   |       |
| **descriptorId**     | string     | The UUID of the descriptor.                                                                                                       | 6.0.0   |       |
| **deviceId**         | string     | The address of the device that the descriptor belongs to.                                                                         | 6.0.0   |       |
| **serviceId**        | string     | The UUID of the service that the descriptor belongs to.                                                                           | 6.0.0   |       |
| **timeout**          | number     | The timeout for the write operation in milliseconds. If the operation takes longer than this value, the promise will be rejected. | 5000    | 6.0.0 |
| **value**            | number\[\] | The value bytes of the descriptor.                                                                                                | 6.0.0   |       |

#### PermissionStatus[¶](#permissionstatus "Permanent link")

| Prop                 | Type                                | Description                                                                 | Since |
| -------------------- | ----------------------------------- | --------------------------------------------------------------------------- | ----- |
| **bluetooth**        | [PermissionState](#permissionstate) | Permission state for using bluetooth. Only available on iOS.                | 6.0.0 |
| **bluetoothConnect** | [PermissionState](#permissionstate) | Permission state for connecting to a BLE device. Only available on Android. | 6.0.0 |
| **bluetoothScan**    | [PermissionState](#permissionstate) | Permission state for scanning for BLE devices. Only available on Android.   | 6.0.0 |
| **location**         | [PermissionState](#permissionstate) | Permission state for using location services. Only available on Android.    | 6.0.0 |
| **notifications**    | [PermissionState](#permissionstate) | Permission state for using notifications. Only available on Android.        | 6.0.0 |

#### BluetoothLowEnergyPluginPermission[¶](#bluetoothlowenergypluginpermission "Permanent link")

| Prop            | Type                                 | Description                 | Default                                                                                             |
| --------------- | ------------------------------------ | --------------------------- | --------------------------------------------------------------------------------------------------- |
| **permissions** | BluetoothLowEnergyPermissionType\[\] | The permissions to request. | \['bluetooth', 'bluetoothAdmin', 'bluetoothConnect', 'bluetoothScan', 'location', 'notifications'\] |

#### PluginListenerHandle[¶](#pluginlistenerhandle "Permanent link")

| Prop       | Type                |
| ---------- | ------------------- |
| **remove** | () => Promise<void> |

#### CharacteristicChangedEvent[¶](#characteristicchangedevent "Permanent link")

| Prop                 | Type       | Description                                    | Since |
| -------------------- | ---------- | ---------------------------------------------- | ----- |
| **characteristicId** | string     | The UUID of the characteristic.                | 6.0.0 |
| **deviceId**         | string     | The address of the device.                     | 6.0.0 |
| **serviceId**        | string     | The UUID of the service.                       | 6.0.0 |
| **value**            | number\[\] | The changed value bytes of the characteristic. | 6.0.0 |

#### CharacteristicWriteRequestEvent[¶](#characteristicwriterequestevent "Permanent link")

| Prop                 | Type       | Description                                     | Since |
| -------------------- | ---------- | ----------------------------------------------- | ----- |
| **characteristicId** | string     | The UUID of the characteristic.                 | 7.2.0 |
| **serviceId**        | string     | The address of the device.                      | 7.2.0 |
| **value**            | number\[\] | The value bytes to write to the characteristic. | 7.2.0 |

#### DeviceConnectedEvent[¶](#deviceconnectedevent "Permanent link")

| Prop         | Type   | Description                          | Since |
| ------------ | ------ | ------------------------------------ | ----- |
| **deviceId** | string | The address of the connected device. | 7.1.0 |
| **name**     | string | The name of the connected device.    | 7.1.0 |

#### DeviceDisconnectedEvent[¶](#devicedisconnectedevent "Permanent link")

| Prop         | Type   | Description                             | Since |
| ------------ | ------ | --------------------------------------- | ----- |
| **deviceId** | string | The address of the disconnected device. | 6.0.0 |
| **name**     | string | The name of the disconnected device.    | 6.0.0 |

#### DeviceScannedEvent[¶](#devicescannedevent "Permanent link")

| Prop     | Type   | Description                                                  | Since |
| -------- | ------ | ------------------------------------------------------------ | ----- |
| **id**   | string | The address of the scanned device.                           | 6.0.0 |
| **name** | string | The name of the scanned device.                              | 6.0.0 |
| **rssi** | number | The RSSI value of the scanned device. Only available on iOS. | 6.0.0 |

### Type Aliases[¶](#type-aliases "Permanent link")

#### PermissionState[¶](#permissionstate "Permanent link")

`'prompt' | 'prompt-with-rationale' | 'granted' | 'denied'`

#### BluetoothLowEnergyPermissionType[¶](#bluetoothlowenergypermissiontype "Permanent link")

`'bluetooth' | 'bluetoothAdmin' | 'bluetoothAdvertise' | 'bluetoothConnect' | 'bluetoothScan' | 'location' | 'notifications'`

### Enums[¶](#enums "Permanent link")

#### ConnectionPriority[¶](#connectionpriority "Permanent link")

| Members           | Value | Description                          | Since |
| ----------------- | ----- | ------------------------------------ | ----- |
| **BALANCED**      | 0     | Balanced connection priority.        | 6.0.0 |
| **HIGH**          | 1     | High connection priority.            | 6.0.0 |
| **LOW\_POWER**    | 2     | Low power connection priority.       | 6.0.0 |
| **PRIORITY\_DCK** | 3     | Digital Car Key connection priority. | 6.0.0 |

## Utils[¶](#utils "Permanent link")

This plugin provides a utility class `BluetoothLowEnergyUtils` that can be used for various Bluetooth Low Energy related operations, for example, converting byte arrays to hexadecimal strings:

`[](#%5F%5Fcodelineno-49-1)import { BluetoothLowEnergyUtils } from '@capacitor-community/bluetooth-low-energy';
[](#%5F%5Fcodelineno-49-2)
[](#%5F%5Fcodelineno-49-3)const convertBytesToHex = (bytes: number[]) => {
[](#%5F%5Fcodelineno-49-4)  return BluetoothLowEnergyUtils.convertBytesToHex({ bytes });
[](#%5F%5Fcodelineno-49-5)};
`

See [docs/utils/README.md](https://github.com/capawesome-team/capacitor-plugins/blob/main/packages/bluetooth-low-energy/docs/utils/README.md) for more information.

## Changelog[¶](#changelog "Permanent link")

See [CHANGELOG.md](https://github.com/capawesome-team/capacitor-plugins/blob/main/packages/bluetooth-low-energy/CHANGELOG.md).

## Breaking Changes[¶](#breaking-changes "Permanent link")

See [BREAKING.md](https://github.com/capawesome-team/capacitor-plugins/blob/main/packages/bluetooth-low-energy/BREAKING.md).

## License[¶](#license "Permanent link")

See [LICENSE](https://github.com/capawesome-team/capacitor-plugins/blob/main/packages/bluetooth-low-energy/LICENSE).

May 17, 2026 

 Back to top 