Bluetooth

Discover, connect to and exchange data with Bluetooth Low Energy and Classic accessories.

Introduced
2011
iOS 5
Kind
Framework
Runs on
Get it from
iOS
5.0+
iPadOS
5.0+
Mac Catalyst
13.1+
macOS
10.7+
tvOS
9.0+
visionOS
1.0+
watchOS
2.0+

Overview

Core Bluetooth gives apps the classes they need to communicate with Bluetooth Low Energy and BR/EDR (Classic) devices. An app can act as a central that scans for, connects to and reads from peripherals, or as a peripheral that publishes services and advertises them to nearby centrals. L2CAP channels offer a stream-based path for larger data transfers.

AccessorySetupKit, added in iOS 18, presents a system picker with the accessory's name and image, so people can pair a Bluetooth or Wi-Fi accessory with one app without a broad Bluetooth permission prompt. In iOS 27, Channel Sounding lets apps measure the distance to supported accessories.

Central role

Scan for, connect to and read from Bluetooth Low Energy peripherals.

Peripheral role

Publish GATT services and advertise them from the app to nearby centrals.

Accessory setup

AccessorySetupKit pairs an accessory to one app through a system picker.

Channel Sounding

Measure the distance to supported Bluetooth LE accessories in iOS 27.

HeartRateScanner.swift
import CoreBluetooth final class HeartRateScanner: NSObject, CBCentralManagerDelegate { private var central: CBCentralManager! override init() { super.init() central = CBCentralManager(delegate: self, queue: nil) } func centralManagerDidUpdateState(_ central: CBCentralManager) { guard central.state == .poweredOn else { return } central.scanForPeripherals(withServices: [CBUUID(string: "180D")]) } func centralManager(_ central: CBCentralManager, didDiscover peripheral: CBPeripheral, advertisementData: [String: Any], rssi RSSI: NSNumber) { print("Found \(peripheral.name ?? "unnamed") at \(RSSI) dB") } }

History

How it grew up.

2011

Core Bluetooth

iOS 5 and macOS 10.7 introduce CBCentralManager for Bluetooth Low Energy.

2012

Peripheral role

iOS 6 adds CBPeripheralManager, letting apps advertise and serve their own data.

2017

L2CAP channels

iOS 11 adds CBL2CAPChannel for stream-based data transfer with a peer.

2024

AccessorySetupKit

iOS 18 brings a system picker for pairing Bluetooth and Wi-Fi accessories.

2026

Channel Sounding

iOS 27 adds Channel Sounding APIs to measure distance to Bluetooth accessories.