DEV Community

Cover image for Python End-of-Life Dates - Official EOL Schedule for Every Version
endoflife-ai
endoflife-ai

Posted on • Originally published at endoflife.ai

Python End-of-Life Dates - Official EOL Schedule for Every Version

Python 3.8 reached end of life in October 2024. Python 3.9 followed in October 2025. Python 3.10 and 3.11 both hit EOL on October 31, 2026 - six months from now.

And Python 2.7 has been dead since January 2020. It still runs in more production environments than anyone admits.

This is the single reference for Python end-of-life dates across every major version - with EOL Risk Scores, migration notes, and plain-English guidance on what to do if you're running past end of support.

Python 3.11 EOL is October 31, 2026 - approximately 6 months away. If your stack runs Python 3.11, start migration planning today. Migrations take longer than expected when dependencies are involved.


Complete Python EOL Schedule

Python releases a new minor version (3.x) roughly every October and supports each version for five years.

Version Released End of Life Status EOL Risk Score
Python 2.7 Jul 2010 Jan 1, 2020 🔴 EOL 98 Critical
Python 3.6 Dec 2016 Dec 23, 2021 🔴 EOL 95 Critical
Python 3.7 Jun 2018 Jun 27, 2023 🔴 EOL 92 Critical
Python 3.8 Oct 2019 Oct 31, 2024 🔴 EOL 88 Critical
Python 3.9 Oct 2020 Oct 31, 2025 🔴 EOL 82 Critical
Python 3.10 Oct 2021 Oct 31, 2026 ⚠️ EOL in 6 months 48 Medium
Python 3.11 Oct 2022 Oct 31, 2026 ⚠️ EOL in 6 months 44 Medium
Python 3.12 Oct 2023 Oct 31, 2028 ✅ Stable 22 Low
Python 3.13 Oct 2024 Oct 31, 2029 ✅ Latest 15 Low

⚠️ Python 3.10 and 3.11 both reach EOL on October 31, 2026. Two major Python versions going end-of-life on the same date means a significant portion of the Python ecosystem will be unpatched simultaneously.


Python 3.8 - End of Life October 31, 2024

Python 3.8 reached end of life on October 31, 2024. No security patches, no bug fixes, no CVE remediation.

Python 3.8 became the default Python on Ubuntu 20.04 LTS - which means any server still running Ubuntu 20.04 is almost certainly running Python 3.8 as its system Python.

The double EOL problem: Ubuntu 20.04 reached EOL in April 2025. Its system Python is 3.8, also EOL. Two compounding unpatched runtimes on the same server.

Migration path to Python 3.12:

  • Run python -m py_compile on your codebase against 3.12 to catch syntax issues early
  • Check distutils usage - removed in Python 3.12
  • Replace asyncio.get_event_loop() with asyncio.get_running_loop()
  • Use pyupgrade --py312-plus to automatically modernize syntax

→ Python 3.8 EOL Risk Score Card


Python 3.9 - End of Life October 31, 2025

Python 3.9 reached end of life on October 31, 2025. It introduced built-in generic types (list[int] instead of List[int]), the | merge operator for dicts, and became the default Python on Ubuntu 22.04 LTS.

The Docker problem: Many Docker base images still use python:3.9 as their foundation. If you're pulling from Docker Hub without pinning to a specific digest, you may be running 3.9 in containers without realising it.

Check your containers:

docker inspect <image> | grep -i python
Enter fullscreen mode Exit fullscreen mode

If you see 3.9 or earlier, update your Dockerfiles to FROM python:3.12-slim and rebuild.

→ Python 3.9 EOL Risk Score Card


Python 3.11 - End of Life October 31, 2026

Python 3.11 reaches end of life on October 31, 2026 - six months from now.

It was the fastest Python release in years - benchmarks showed 10-60% performance improvements over Python 3.10. Many teams upgraded specifically for these gains and then stayed there.

Six months sounds comfortable. It isn't - especially for larger codebases with complex dependency trees. The average Python migration takes 4-8 weeks when you factor in dependency compatibility testing, CI pipeline updates, and staged rollouts.

Start now. Key steps:

  • Create a test venv: python3.12 -m venv venv-test and install your full requirements.txt
  • Check setuptools and pkg_resources usage - both are deprecated in newer pip
  • tomllib is now in stdlib - remove the tomli backport dependency
  • Run your full test suite on 3.12 in CI before touching production

→ Python 3.11 EOL Risk Score Card


Python 3.12 - Current Stable, Supported Until 2028

Python 3.12 is the recommended migration target. Supported until October 31, 2028 - a solid two-year runway from today.

Key changes to be aware of:

  • distutils removed - most commonly triggered by old setup.py-based packages
  • Removed modules: aifc, cgi, cgitb, chunk, crypt, imghdr, mailcap, pipes, sndhdr, telnetlib, uu
  • @override decorator for type checking
  • Further performance improvements from the Faster CPython project

Check for removed module usage:

grep -r "import distutils\|from distutils" .
Enter fullscreen mode Exit fullscreen mode

→ Python 3.12 EOL Risk Score Card


Python 3.13 - Latest Release

Python 3.13 is the latest release, available since October 2024 and supported until October 31, 2029. It introduces an experimental free-threaded mode (PEP 703 - removing the GIL) and a new interactive REPL.

For most production deployments, Python 3.12 is the right choice today. The free-threaded mode is experimental. Adopt 3.13 when your key dependencies have confirmed compatibility.


How to Migrate Safely - 5 Steps

Step 1 - Test the target version first
python3.12 -m venv venv-test then pip install -r requirements.txt. Every failure is a migration task.

Step 2 - Check for removed modules
Run grep -r "import distutils\|from distutils" . across your codebase. distutils removal is the most common blocker.

Step 3 - Use pyupgrade

pip install pyupgrade
pyupgrade --py312-plus **/*.py
Enter fullscreen mode Exit fullscreen mode

Automatically updates type hints, string formatting, and deprecated patterns.

Step 4 - Update CI before production
Change your CI matrix to include Python 3.12. Clean CI run before any production change.

Step 5 - Update Docker base images
FROM python:3.11 becomes FROM python:3.12-slim. Rebuild and test.


EOL Risk Scores - What They Mean

Every Python version page on endoflife.ai carries an EOL Risk Score - a 0-100 score measuring actual security and operational risk. Four factors:

  • EOL Recency (40pts) - how long since support ended
  • Attack Surface (30pts) - Python runs web servers, data pipelines, scripts. CVEs in EOL versions are never patched.
  • CISA KEV Exposure (20pts) - known exploited vulnerabilities in the CISA catalog
  • Extended Support Availability (10pts) - commercial options to reduce urgency
Version Score Band
Python 2.7 98 🔴 Critical
Python 3.8 88 🔴 Critical
Python 3.9 82 🔴 Critical
Python 3.10 48 🟡 Medium
Python 3.11 44 🟡 Medium
Python 3.12 22 🟢 Low
Python 3.13 15 🟢 Low

Check Your Full Stack

Python runtime EOL is one piece of the puzzle. Your pip packages, frameworks (Django, Flask, FastAPI), and OS runtime each have their own end-of-life dates.

Use the free EOL Checker or Stack Scanner at endoflife.ai to audit your entire dependency tree - no account required.


This article is part of The EOL Intelligence Report series on DEV.to. EOL dates sourced from endoflife.date, Python Software Foundation, and CISA KEV Catalog.

Top comments (0)