skillfed

pyicloud

PyiCloud is a module which allows pythonistas to interact with iCloud webservices.

pyicloud v2.6.5 105.3K downloads/30d#12,704 on PyPI152
Permissive license MIT Active released

What it is and what it does

PyiCloud is a Python client library for Apple's iCloud web services. It authenticates with an Apple ID and provides programmatic access to iCloud features: finding devices, managing calendars and contacts, syncing photos, accessing notes and reminders, and inspecting account details. The library wraps iCloud's web API and handles authentication, including two-factor authentication and security-key challenges via FIDO2.

The package includes both a Python API (instantiate PyiCloudService with credentials) and a command-line tool (icloud subcommands for auth, devices, photos, calendar, etc.). Passwords can be stored in the system keyring to avoid repeated prompts. The library depends on requests for HTTP, cryptography and fido2 for security, keyring for credential storage, and pydantic for data validation.

Use it for:

  • Locate or retrieve information about Apple devices registered to an account programmatically.
  • Sync iCloud photos to a local directory on a schedule or on-demand.
  • Query or manipulate iCloud calendars, contacts, notes, and reminders from Python scripts.
  • Build automation workflows that interact with iCloud services without manual web login.
  • Use the icloud CLI to manage iCloud account operations from shell scripts or cron jobs.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

PyiCloud provides Python access to iCloud web services, including device location, calendars, contacts, photos, and account management, with both a library API and command-line interface.

Yes, if you need programmatic access to iCloud services. The library is actively maintained, has low install friction, carries an MIT license, and supports current Python versions (3.10–3.14). No known vulnerabilities. Caveat: Apple's iCloud API is not officially documented, so compatibility may shift; review the terms of use before deploying in production.

Install

pyicloud on PyPI

pip

pip install pyicloud

uv

uv add pyicloud

poetry

poetry add pyicloud

Installing pyicloud

Before you install

Low install friction with a pure-Python wheel and stable maintenance: last commit 2026-08-10, active status, and 11 runtime dependencies that are all widely-used libraries (requests, cryptography, keyring, protobuf, pydantic). Requires Python 3.10 or later.

License in practice

MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute this package freely provided you retain the license notice.

Quickstart

pip install pyicloud

from pyicloud import PyiCloudService
api = PyiCloudService('user@apple.com', 'password')
devices = api.devices

Requires Python 3.10 or later; Apple ID credentials and may require two-factor authentication setup.

Verify before relying

  • Whether two-factor authentication is required for all accounts or only some.
  • Rate limits or throttling imposed by Apple's iCloud API.
  • Stability and compatibility of the iCloud API endpoints being called.

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 11 — certifi, cryptography, fido2, keyring, keyrings.alt, protobuf, pydantic, requests, srp, tinyhtml, tzlocal
Maintenance actively maintained — 66 days since the last release
Last repo commit
First released
Downloads 105,343/month — #12,704 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: pyicloud-2.6.5-py3-none-any.whl

Keywords: icloud, find-my-iphone

Development Status :: 5 - Production/StableIntended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: Software Development :: Libraries

Tags

icloud api pythonfind my iphone programmaticicloud contacts calendar accessapple id web services clienticloud photos sync downloadicloud device location trackingicloud cli command line
icloud-clientapple-id-authcli-tool

More Libraries packages