A lightweight native macOS menu bar utility inspired by the Apple Watch Noise app. DeciBar continuously estimates ambient sound levels using your Mac microphone, logs historical data, and provides insights into weekly noise exposure. It is built to feel like a first party Apple application with a clean architecture and a polished user experience.
DeciBar lives in your menu bar and shows a live estimate of the ambient sound around your Mac. It tracks daily averages and peaks, records readings efficiently in the background, and surfaces trends through a refined dashboard. All processing happens locally on your Mac.
Estimated values are treated as ambient sound estimates rather than laboratory calibrated SPL measurements.
- Current estimated decibel level with smoothing
- Peak level tracking
- Daily average
- Efficient throttled updates
Three display modes:
- Icon and level
- Level only
- Icon only
The menu surfaces the current noise level, today average, today peak, connected audio device, the active warning threshold, and quick access to the dashboard, settings, and quit.
- Configurable thresholds at 75, 80, 85, and 90 decibels
- Native macOS notification when noise stays above the threshold
- Cooldown timer to prevent notification spam
- Exposure duration tracking
- Readings stored every 5 to 15 seconds rather than on every microphone update
- Each reading captures timestamp, estimated level, peak, and the connected audio device
- Persistence powered by SwiftData
Automatic detection of the current default output device using CoreAudio, including AirPods, Bluetooth headphones, Bluetooth speakers, built in speakers, Studio Display, USB audio, HDMI, and AirPlay. The active device updates automatically and every stored reading records it.
A polished native dashboard with a live circular gauge, today statistics, weekly history, device statistics, a weekly heatmap, and a scrollable timeline. Charts are rendered with Swift Charts.
Configure the warning threshold, sampling interval, notification cooldown, launch at login, menu bar display style, appearance, and data retention. Export history to CSV or clear all history.
Everything is processed locally. No analytics, no cloud storage, and no tracking. Audio is never recorded or transmitted. Microphone permission is requested only when needed, and denied permissions are handled gracefully.
- Native SwiftUI application
- macOS 15 or later
- MenuBarExtra
- SwiftData persistence
- Swift Concurrency with async and await
- MVVM architecture
- AVFoundation and CoreAudio
- Swift Charts
The project is organized into focused modules covering models, services, view models, and views.
DecibelBar/
App/ App entry point, delegate, and window management
Models/ SwiftData models and value types
Services/
AudioEngine/ Microphone metering and permission
DeviceMonitor/ CoreAudio output device detection
Notifications/ Threshold warnings and cooldown
Persistence/ SwiftData store, aggregation, and CSV export
ViewModels/ Observable coordinators for the UI
Views/
MenuBar/ Menu bar label and popover
Dashboard/ Dashboard window and sections
Settings/ Settings window
Components/ Reusable UI building blocks
Charts/ Swift Charts visualizations
Utilities/ Settings store, formatters, and helpers
Resources/ Assets, entitlements, and Info.plist
Open the project in Xcode and run the DeciBar scheme, or build from the command line.
xcodebuild -project DecibelBar.xcodeproj -scheme DecibelBar -configuration Release build
On first launch the app requests microphone access so it can estimate ambient sound levels.
Released under the MIT License. See the LICENSE file for details.