<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AVFAudio",
  "identifier" : "/documentation/AVFAudio/AVAudioSession/PortOverride/speaker",
  "metadataVersion" : "0.1.0",
  "role" : "Case",
  "symbol" : {
    "kind" : "Case",
    "modules" : [
      "AVFAudio"
    ],
    "preciseIdentifier" : "c:@E@AVAudioSessionPortOverride@AVAudioSessionPortOverrideSpeaker"
  },
  "title" : "AVAudioSession.PortOverride.speaker"
}
-->

# AVAudioSession.PortOverride.speaker

A value that indicates to override the current inputs and outputs, and route audio to the built-in speaker and microphone.

```
case speaker
```

## Discussion

This override type is only valid for the [`playAndRecord`](/documentation/AVFAudio/AVAudioSession/Category-swift.struct/playAndRecord) category.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)