--- id: iso8601 version: "2.1.0" license: MIT license_treatment: permissive maintenance: aging --- # iso8601 — Simple module to parse ISO 8601 dates License: permissive · Maintenance: aging · Downloads: 12.7M/mo ## What it is and what it does iso8601 is a lightweight, dependency-free parser that converts ISO 8601 formatted date strings into Python datetime objects. It handles the most common ISO 8601 formats—full timestamps with timezones, date-only strings, partial times—and applies sensible defaults (UTC timezone, day/month of 1) when components are omitted. The parser is permissive by design: it accepts space instead of T as a date-time separator, tolerates missing leading zeros in days and months, and lets you override the default timezone. The package is intentionally minimal. It does one thing: take an ISO 8601 string and return a datetime. If you need richer date manipulation, timezone handling, or parsing of non-ISO formats, the description itself points toward arrow, pendulum, python-dateutil, or Python 3's built-in datetime.fromisoformat(). For straightforward ISO 8601 parsing in legacy codebases or when you want to avoid extra dependencies, iso8601 is a stable, proven choice. Use it for: - Parse API response timestamps that come in ISO 8601 format into Python datetime objects for comparison or manipulation. - Convert log entries with ISO 8601 timestamps into datetime objects for time-based filtering or analysis. - Handle user-submitted date strings in ISO 8601 format from web forms or data imports. - Work with database exports or JSON data that use ISO 8601 date representation. - Normalize mixed date formats by accepting ISO 8601 strings and converting them to a consistent datetime representation. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Parses ISO 8601 date strings (e.g. 2007-01-14T20:34:22+00:00) into Python datetime objects, handling common date/time formats and timezone specifications. Yes, if you need straightforward ISO 8601 parsing with zero dependencies and don't require advanced date manipulation. The package is stable, permissively licensed, and widely used (top 5000 on PyPI). However, consider Python 3.11+ built-in datetime.fromisoformat() first—it now handles most ISO 8601 cases natively. Install iso8601 only if you need the lenient parsing (space instead of T, missing leading zeros) or must support Python 3.7–3.10. ## Install pip install iso8601 uv add iso8601 poetry add iso8601 ## Installing iso8601 Before you install: Low install friction with no runtime dependencies. Aging maintenance status (last release 2023-10-03, last commit 2025-03-06) but repository remains active and untested against Python versions below 3.7. License in practice: MIT license (permissive) means you can use, modify, and distribute this package freely in commercial and open-source projects with minimal restrictions. Quickstart: pip install iso8601 import iso8601 dt = iso8601.parse_date("2007-01-25T12:00:00Z") print(dt) # datetime.datetime(2007, 1, 25, 12, 0, tzinfo=) Requires Python 3.7 or later (>=3.7,<4.0). Verify before relying: - Whether the package handles all ISO 8601 edge cases or only the common forms mentioned in the description. - Performance characteristics when parsing large volumes of date strings. - Whether the aging maintenance status indicates sufficient stability or signals future compatibility concerns. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: aging - Downloads: 12.7M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags iso 8601 date parsing, parse iso date string, datetime from iso format, iso 8601 parser, timezone aware date parsing, iso date string to datetime, date-parsing, iso-8601, timezone-aware [View on SkillFed](https://skillfed.io/packages/iso8601) · [View on PyPI](https://pypi.org/project/iso8601/)