future
Clean single-source support for Python 3 and 2
Decision gist · record as of 2026-08-14
Yes, if you maintain code that must support both Python 2 and Python 3. The package is mature, actively maintained, has no dependencies, and carries no security risk. However, this is primarily useful for legacy systems. For new projects, Python 3-only code is the standard approach.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Designed for Python 2.6, 2.7 and Python 3.3+; requires requires_python >=2.6, !=3.0.*, !=3.1.*, !=3.2.*
- Low friction installation with no runtime dependencies.
- Actively maintained with a stable release history since 2013-07-14.
License · maintenance · safety
MIT (permissive) — MIT license (permissive) means you can use, modify, and distribute this package freely with minimal restrictions.
last release 2024-02-21 (905 days) · last repo commit 2026-07-24 · 1,189 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 71,389,919 downloads/mo, #465 on PyPI
Alternatives
Verify before relying
pip install future
from __future__ import absolute_import, division, print_function, unicode_literals
from builtins import bytes, dict, int, list, str, range, open
# Write standard Python 3 code that runs on both Python 2 and 3- Whether Python 2 support remains practically relevant given its end-of-life status.
- Performance overhead of compatibility shims compared to native Python 3 code.
What it is and what it does
future is a compatibility layer that lets you write Python 3-style code that runs on both Python 2 and Python 3. It provides backported builtins and standard library reorganization (PEP 3108) so that imports like `from builtins import str, range, open` work on Python 2 with Python 3 semantics, while having no effect on Python 3. It also includes futurize, a script that automatically converts existing Python 2 or Python 3 code to be compatible with both versions.
The package has zero runtime dependencies and installs cleanly. It is mature (Development Status 6), actively maintained with last commit 2026-07-24, and widely used in the top 1000 on PyPI. There are no known security vulnerabilities. The MIT license is permissive and places no restrictions on use or distribution.
Use it for
- Maintaining a library or application that must support both Python 2 and Python 3 simultaneously.
- Migrating Python 2 codebases to Python 3 while keeping them runnable on both versions during transition.
- Writing new code once in Python 3 style and automatically supporting Python 2 with minimal rewrites.
- Using Python 3 standard library interfaces (like urllib.request, html.parser) on Python 2.
- Automating conversion of existing code to dual-version compatibility using the futurize tool.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you maintain code that must support both Python 2 and Python 3.
The package is mature, actively maintained, has no dependencies, and carries no security risk. However, this is primarily useful for legacy systems. For new projects, Python 3-only code is the standard approach.
Install
future on PyPI
Before you install
Low friction installation with no runtime dependencies. Actively maintained with a stable release history since 2013-07-14.
Designed for Python 2.6, 2.7 and Python 3.3+; requires requires_python >=2.6, !=3.0.*, !=3.1.*, !=3.2.*
License in practice
MIT license (permissive) means you can use, modify, and distribute this package freely with minimal restrictions.
Quickstart
pip install future
from __future__ import absolute_import, division, print_function, unicode_literals
from builtins import bytes, dict, int, list, str, range, open
# Write standard Python 3 code that runs on both Python 2 and 3
Verify before relying
- Whether Python 2 support remains practically relevant given its end-of-life status.
- Performance overhead of compatibility shims compared to native Python 3 code.
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release >=2.6, !=3.0.*, !=3.1.*, !=3.2.* |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 905 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 71,389,919 / month, #465 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 6 - MatureIntended Audience :: DevelopersLicense :: OSI ApprovedLicense :: OSI Approved :: MIT LicenseProgramming Language :: PythonProgramming Language :: Python :: 2Programming Language :: Python :: 2.6Programming Language :: Python :: 2.7Programming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.3Programming Language :: Python :: 3.4Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9 |
Evidence: future-1.0.0-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “single codebase python 2 and 3”
- futureProvides Python 3 syntax and semantics on Python 2, allowing a single…
- htaghtag is a Python GUI toolkit for building web, desktop, and mobile…
- django-upgradeAutomatically modernizes Django project code by applying syntax and…
Give your agent the search over MCP, or paste the wish link into any chat.
Similar packages
fissix is a backport of Python's lib2to3 library with enhancements, providing tools for automated code transformation and refactoring across Python versions.
Install it if you need to build refactoring tools, automate code migrations, or integrate lib2to3 into a pipeline.
Provides a flat-namespace compatibility layer for Python 2/3 code migration, consolidating commonly needed imports into a single `mo_future` module to avoid discovering them across multiple sub-modules.
However, the aging maintenance status (425 days since last release) and small user base (2 GitHub stars) suggest this is a niche tool—if you are starting a new…
Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.
Provides a backport of Python's traceback module to older Python versions, allowing consistent traceback formatting and manipulation across Python 2.6+ and Python 3.2+.
Install only if you are maintaining legacy code that must run on Python 2.6–3.4 and cannot upgrade—otherwise, use the standard library traceback module.
Conditionally installs enum34 on Python versions older than 3.4; on Python 3.4+ it is a no-op.
Eight provides a compatibility layer that lets you write Python 3 code and run it on Python 2.7 with minimal changes, offering Python 3 names and behaviors as backports.
See also subprocess32 · futures · configparser2 · django-utils-six