A Python script that reads the total bytes written to your Mac's SSD and displays it in terabytes (TB). Useful for tracking drive wear over time.
- macOS
- Python 3
- smartmontools
brew install smartmontoolsgit clone https://github.com/nerryc/mac-total-bytes-written.git
cd mac-total-bytes-written
python3 main.pyData Units Written: 1,234,567 units, which is approximately 12.34 TB
- Reads from
/dev/disk0by default — editmain.pyif your SSD is at a different path - Uses
smartctl -Aunder the hood; requires no root on most Macs but may prompt for permissions on some systems
MIT — see LICENSE.