Where is the Screen Time database on Mac? (Biome and knowledgeC)

Updated

Screen Time on a Mac is built from two kinds of local storage: the older knowledgeC.db SQLite database and the newer Biome streams under ~/Library/Biome. Since macOS 13 Apple has moved more usage data into Biome, which uses an undocumented binary format (often called SEGB) rather than SQLite. Both are protected by macOS and need Full Disk Access to read, and both keep only about the same few weeks as the Screen Time report.

The two stores

knowledgeC.db (~/Library/Application Support/Knowledge/knowledgeC.db): a SQLite database with an ZOBJECT table of events like /app/usage and /app/webUsage. It's readable with the sqlite3 tool and well described in forensic write-ups. knowledgeC.db explained covers it in detail.

Biome (~/Library/Biome/): a newer framework Apple uses for many kinds of on-device events. App usage is recorded in a stream called App.InFocus, under ~/Library/Biome/streams/. Each stream is a folder of segment files rather than one database. There's also ~/Library/Biome/sync/, which holds information about the other devices that sync with this Mac.

What changed and why it matters

Researchers and open-source tools have documented the shift: on recent macOS versions, usage synced from an iPhone through Share Across Devices is no longer written to knowledgeC.db but to Biome, in a remote subfolder of the App.InFocus stream (one folder per synced device). See, for example, Magnet Forensics' write-up on SEGB and Biome and this collection of notes on accessing Screen Time data.

In practice:

How to look at the files yourself

  1. Open Apple menu > System Settings > Privacy & Security > Full Disk Access and turn it on for Terminal. Quit and reopen Terminal.
  2. List the streams: ls ~/Library/Biome/streams/restricted/ ~/Library/Biome/streams/public/ 2>/dev/null
  3. Look for an App.InFocus folder and, inside it, local (this Mac) and remote (synced devices).
  4. Copy the folder somewhere of your own before experimenting: cp -R ~/Library/Biome/streams/restricted/App.InFocus ~/biome-copy/
  5. Turn Full Disk Access for Terminal off when you're done.

To decode the records you'll need a third-party SEGB parser. Treat the output as approximate: tool maintainers note that foreground durations are reconstructed and may not match the Screen Time report exactly.

Never edit or delete files in ~/Library/Biome or the Knowledge folder. That can break Screen Time and other system features.

How long Biome keeps Screen Time data

About the same as Screen Time itself: a few weeks. Biome isn't a long-term archive; old segments are pruned automatically. If you want months or years of history, it has to be copied out regularly before it's removed. See how far back Screen Time goes.

Is there a Screen Time database on iPhone?

Yes, iOS uses similar stores, but they're not accessible on a normal iPhone. The practical way to work with iPhone usage is on a Mac, after it syncs there with Share Across Devices.

Common questions

Why does Screen Time on Mac need Full Disk Access to be read?

Both knowledgeC.db and Biome are in protected locations. Full Disk Access is the only way macOS allows an app or Terminal to read them.

Is Biome data sent to Apple?

Biome is local on-device storage. Screen Time's sync between your own devices is end-to-end encrypted, according to Apple's iCloud data security overview. See who can see your Screen Time.

Can I export from Biome to CSV?

Only with third-party parsers or scripts, and they need updating when Apple changes the format. Screen Time CSV export shows the knowledgeC.db route.

Where Screen Time History helps

Screen Time History is a Mac app that reads Screen Time data with Full Disk Access and follows these storage changes for you. It keeps every day from the day it's installed, including your iPhone when Share Across Devices is on, and exports per-app, per-day data. It can't recover days the system already pruned.


Screen Time History · Privacy · Not affiliated with Apple.