Python 2.7 EOL FAQ
Last updated 09 January 2020
Table of Contents
- Is Heroku removing Python 2 from the platform?
- What about my Python 2 applications currently on heroku?
- When will Python 2 be sunset/reach end of life on Heroku?
- What do I need to do to run my applications after Python 2 is sunset/reaches end of life ?
- Can I run any CPython 2 applications after the Heroku 18 stack?
- Why is Python 2 being sunset?
Is Heroku removing Python 2 from the platform?
Python 2.7.17 applications will continue to build and run on Heroku 18 for the lifetime of the stack, until April 2023.
However, Python 2.7 on Heroku will no longer receive security updates after January 1, 2020, as it has reached it’s community specified end of life date.
Because of this, Heroku platform support for these applications will end as soon as February 1st, 2021. On that sunset date, these applications will continue to build and run, but they will no longer fall under our Support Policy.
We recommend that you migrate your app to a supported Python runtime to ensure that it’s running in a secure environment as soon as possible.
What about my Python 2 applications currently on heroku?
While many developers have migrated to Python 3 already, Heroku recognizes that just as many may not be ready for Heroku to be incompatible with Python 2.
If you are unable to migrate to Python 3, you are encouraged to try out Pypy - see Supported Python Runtimes for more details.
When will Python 2 be sunset/reach end of life on Heroku?
Official support for Python 2.7 on Heroku will end as soon as February 1, 2021. This means that Python 2 applications will fall outside of our support scope, and will not be eligible for platform support without first migrating to a supported version of Python.
What do I need to do to run my applications after Python 2 is sunset/reaches end of life ?
We strongly encourage you to migrate to Python 3. However, you do not need to take any action for your applications to continue to run after February 1st, 2021. On that date, your application will build and run, but it will no longer fall under the Heroku Support Policy.
Can I run any CPython 2 applications after the Heroku 18 stack?
No. CPython 2 applications will not build on future Heroku stacks.
Why is Python 2 being sunset?
Heroku is following the Python community by removing CPython 2 from official support. The decision to discontinue development on CPython 2 is is a community led effort to enable core Python maintainers to better support the language. Python is a free and open source language, and we all depend on these volunteer maintainers to keep Python performant and secure. The purpose of this document is to clarify the impacts of this decision on your applications