icloudcli reads your local SQLite databases directly — Photos, Messages, Contacts, and more. No API token, no login. Find storage hogs, search conversations, export contacts, and automate it all with JSON output.
Quick Install
Open Source · Apache-2.0
Use cases
Every command runs locally against your on-device databases — no network, no app launch. Pipe to jq or use --agent to wire it into any AI workflow.
AI workflows
Copy a prompt, paste it into Claude, Cursor, Codex, or any agent with terminal access — it runs the commands and handles the rest.
Open source lives on community support. A star takes one second and helps other developers find this tool.
Apache-2.0 · free forever · macOS onlyReference
All commands accept --json, --compact, --no-color, and --agent (sets all three). Use --library to point at a non-default Photos library path.
photos top
Top N heaviest files across all media types. Flags: --limit, --type all|photo|video
Live
photos videos
Largest videos sorted by file size. Flags: --limit, --year, --month
Live
photos storage
Storage breakdown by media type (photo/video) and by year
Live
photos stats
Total item count and total library size
Live
photos delete
Move items to Recently Deleted. Dry run by default; add --confirm to act. Requires Photos.app.
Live
photos search
Search by location, date range, or person
Coming
photos ask
Natural language query over your library
Coming
messages list-chats
List all conversations — name, handle, last message date, and message count
Coming
messages search
Search messages by contact, keyword, or date range. Flags: --from, --text, --after, --before
Coming
messages export
Export a full conversation thread to JSON or plain text
Coming
contacts list
List all contacts with filter and sort options. Reads AddressBook SQLite directly.
Coming
contacts search
Search contacts by name, email, phone, or note
Coming
contacts export
Export all contacts to JSON — no vCard, no Contacts.app
Coming
findmy devices
List all Apple ID devices — name, last-seen time, and battery level from local Find My cache
Coming
findmy items
List AirTags and third-party Find My accessories with last-seen location
Coming
doctor
Pre-flight check — verifies macOS, Photos.app, library path, schema, and asset count. Run this first.
Live
Get started
Requires macOS 13+. Run icloud-pp-cli doctor after installing to verify your setup.