Open this example in the interactive library
Source code
from datetime import date
print(date.fromisoformat('2026-10-22'))Sample output
2026-10-22

Parse an ISO date. A self-contained example using the Python standard library.
Open this example in the interactive library
from datetime import date
print(date.fromisoformat('2026-10-22'))2026-10-22