plistlib: read and write Apple property list files
Answer: plistlib reads and writes Apple property list files used primarily on macOS and iOS. It supports binary and XML formats. Use load and dump for files, or loads and dumps for bytes and strings.
What a plist can hold
The module is an interface for reading and writing property list files used by Apple, mainly on macOS and iOS.
Both a binary format and an XML format are supported.
Serialization is simple: dictionaries, lists, numbers, and strings are the basic object types.
A dictionary, or a frozen dictionary, is usually the top-level object.
Reading and writing
dump and load write and parse a plist file.
dumps and loads work with plist data held in bytes or string objects.
Format constants include FMT_XML and FMT_BINARY. Use None to autodetect the file format.
See also
Claims
- id: C1 claim: plistlib reads and writes Apple property list files on macOS and iOS. source: S1 evidence: "files used by Apple, primarily on macOS and iOS"
- id: C2 claim: It supports both binary and XML formats. source: S1 evidence: "supports both binary"
- id: C3 claim: Use dump and load for plist files. source: S2 evidence: "use the :func:
dumpand"
- id: C4 claim: FMT_XML is the XML file format. source: S2 evidence: "XML file format"
Sources
- [S1] plistlib — Generate and parse Apple .plist files. Python Software Foundation. https://docs.python.org/3/library/plistlib.html . License: PSF License Version 2. Accessed 2026-11-23.
- [S2] plistlib documentation (source). CPython. https://raw.githubusercontent.com/python/cpython/main/Doc/library/plistlib.rst . License: PSF License Version 2. Accessed 2026-11-23.
License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: Python Software Foundation, plistlib — Generate and parse Apple .plist files; CPython, plistlib documentation (source). PSF-2.0 (https://docs.python.org/3/license.html). Copyright Python Software Foundation. Text was condensed and changed from the originals.
License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: Python Software Foundation, plistlib — Generate and parse Apple .plist files; CPython, plistlib documentation (source). PSF-2.0 (https://docs.python.org/3/license.html). Copyright Python Software Foundation.
Cite this
iinventedlight. 2026. "plistlib: read and write Apple property list files." iinventedlight Library, iil:note:jbpw2q6w, version of 2026-11-23. https://iinventedlight.com/library/notes/python-plistlib/. License: CC-BY-4.0.
@misc{iil_note_jbpw2q6w,
author = {{iinventedlight}},
title = {{plistlib: read and write Apple property list files}},
howpublished = {iinventedlight Library},
year = {2026},
date = {2026-11-23},
url = {https://iinventedlight.com/library/notes/python-plistlib/},
note = {Permanent ID iil:note:jbpw2q6w. License: CC-BY-4.0.},
}
Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).
Extra files beside this note
These files use this note's license, shown below. Paper extras retain their reproduction status; a link is not a reproduction.
- python-plistlib.schema.json (schema; CC-BY-4.0)
- python-plistlib.table.json (table; CC-BY-4.0)
For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/python-plistlib.md.