A native macOS menu bar app that automatically manages audio device priorities. Set your preferred order for speakers and microphones - the app automatically switches to the highest-priority connected device.
Website: https://badalotti.dev/audio-priority
- Priority-based auto-switching: Devices are ranked by priority. When a higher-priority device connects, it automatically becomes active.
- Device memory: Remembers your device priority order across reconnects.
- Ignore devices: Hide devices from the list.
- Drag-to-reorder: Reorder devices by dragging.
- Speaker and mic volume: Adjust both volumes with a slider or scroll wheel.
- Graceful volume fallback: Shows "-" when the system volume is unavailable.
- Auto-switch toggle: Enable or disable automatic device switching.
- Menu bar integration: Lightweight, always-available controls.
- macOS 14.0 or later
brew install --cask mateusbadalotti/audio-priority/audio-priorityUpdates via Homebrew.
-
Clone the repository:
git clone https://github.com/mateusbadalotti/audio-priority.git && cd audio-priority
-
Build using the build script:
./build.sh
-
The app will be at
dist/AudioPriority.app
Or open audio-priority.xcodeproj in Xcode and build with ⌘R.
Check the Releases page for pre-built binaries.
- Click a device: Select it as the active device (connected only)
- Drag devices: Reorder priority by dragging the handle
- Ignore device: Hide as speaker or microphone
Use the Auto toggle in the footer to enable or disable automatic device switching.
- Device Discovery: Uses CoreAudio to enumerate audio devices and listen for changes.
- Priority Storage: Device priorities are stored in UserDefaults, keyed by device UID (stable across reconnects).
- Auto-Switching: When devices connect/disconnect, the app automatically selects the highest-priority available device.
audio-priority/
├── AudioPriorityApp.swift # App entry, MenuBarExtra, AudioManager
├── Models/
│ └── AudioDevice.swift # Device model
├── Services/
│ ├── AudioDeviceService.swift # CoreAudio wrapper
│ └── PriorityManager.swift # Priority persistence
└── Views/
├── MenuBarView.swift # Main popover UI
└── DeviceListView.swift # Device list and row components
Contributions are welcome! Please feel free to submit a Pull Request.
MIT License - see LICENSE for details.
Built with SwiftUI and CoreAudio for macOS.
Heavily inspired by https://github.com/tobi/AudioPriorityBar
