---
title: allowBluetoothA2DP
framework: avfaudio
role: symbol
role_heading: Type Property
path: avfaudio/avaudiosession/categoryoptions-swift.struct/allowbluetootha2dp
---

# allowBluetoothA2DP

An option that determines whether you can stream audio from this session to Bluetooth devices that support the Advanced Audio Distribution Profile (A2DP).

## Declaration

```swift
static var allowBluetoothA2DP: AVAudioSession.CategoryOptions { get }
```

## Discussion

Discussion A2DP is a stereo, output-only profile intended for higher bandwidth audio use cases, such as music playback. The system automatically routes to A2DP ports if you configure an app’s audio session to use the ambient, soloAmbient, or playback categories. Starting with iOS 10.0, apps using the playAndRecord category may also allow routing output to paired Bluetooth A2DP devices. To enable this behavior, pass this category option when setting your audio session’s category. Audio sessions using the multiRoute or record categories implicitly clear this option. If you clear it, paired Bluetooth A2DP devices don’t show up as available audio output routes. note: If this option and the allowBluetooth option are both set, when a single device supports both the Hands-Free Profile (HFP) and A2DP, the system gives hands-free ports a higher priority for routing.

## See Also

### Category options

- [allowAirPlay](avfaudio/avaudiosession/categoryoptions-swift.struct/allowairplay.md)
- [allowBluetooth](avfaudio/avaudiosession/categoryoptions-swift.struct/allowbluetooth.md)
- [allowBluetoothHFP](avfaudio/avaudiosession/categoryoptions-swift.struct/allowbluetoothhfp.md)
- [bluetoothHighQualityRecording](avfaudio/avaudiosession/categoryoptions-swift.struct/bluetoothhighqualityrecording.md)
- [defaultToSpeaker](avfaudio/avaudiosession/categoryoptions-swift.struct/defaulttospeaker.md)
- [duckOthers](avfaudio/avaudiosession/categoryoptions-swift.struct/duckothers.md)
- [farFieldInput](avfaudio/avaudiosession/categoryoptions-swift.struct/farfieldinput.md)
- [interruptSpokenAudioAndMixWithOthers](avfaudio/avaudiosession/categoryoptions-swift.struct/interruptspokenaudioandmixwithothers.md)
- [mixWithOthers](avfaudio/avaudiosession/categoryoptions-swift.struct/mixwithothers.md)
- [overrideMutedMicrophoneInterruption](avfaudio/avaudiosession/categoryoptions-swift.struct/overridemutedmicrophoneinterruption.md)
