troposphere
AWS CloudFormation creation library
Decision gist · record as of 2026-08-14
Yes. Troposphere is actively maintained, has no known vulnerabilities, installs with minimal friction, and solves a real problem for teams managing AWS infrastructure as code. The permissive license and broad Python version support (3.8+) make it low-risk to adopt. Install it if you prefer writing infrastructure in Python over hand-editing CloudFormation templates.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Low friction installation as a pure Python wheel with a single runtime dependency (cfn_flip).
- The package is actively maintained with a recent release and has been stable since its early releases.
License · maintenance · safety
BSD-2-Clause (permissive) — BSD-2-Clause is a permissive license that allows commercial use, modification, and distribution with minimal restrictions—suitable for most projects.
last release 2026-05-16 (90 days) · last repo commit 2026-08-14 · 4,945 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 1,281,350 downloads/mo, #4,116 on PyPI
Alternatives
Verify before relying
pip install troposphere
from troposphere import Template, Ref
import troposphere.ec2 as ec2
t = Template()
instance = ec2.Instance("myinstance", ImageId="ami-951945d0", InstanceType="t1.micro")
t.add_resource(instance)
print(t.to_json())- Whether cfn_flip is required at runtime or only for optional output format conversion
- Scope and completeness of AWS resource type coverage relative to current CloudFormation service offerings
What it is and what it does
Troposphere lets you write AWS CloudFormation templates as Python code instead of JSON or YAML. You define AWS resources using Python classes, set their properties, and the library generates valid CloudFormation JSON or YAML output. The library validates resource properties and types as you build the template, catching configuration errors before deployment rather than during stack creation.
It's designed for teams that prefer programmatic infrastructure definition and want type safety and early error detection. The library includes support for AWS resources and basic OpenStack Heat resources. A single optional dependency (cfn_flip) handles output format conversion.
Use it for
- Generate CloudFormation templates programmatically for repeatable infrastructure deployments across environments
- Catch CloudFormation configuration errors at development time through property and type validation
- Build infrastructure templates using Python control flow, functions, and version control-friendly code
- Convert between CloudFormation JSON and YAML formats during template generation and deployment
- Define reusable infrastructure components as Python classes and functions for consistent resource patterns
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Troposphere is actively maintained, has no known vulnerabilities, installs with minimal friction, and solves a real problem for teams managing AWS infrastructure as code. The permissive license and broad Python version support (3.8+) make it low-risk to adopt. Install it if you prefer writing infrastructure in Python over hand-editing CloudFormation templates.
Install
troposphere on PyPI
Before you install
Low friction installation as a pure Python wheel with a single runtime dependency (cfn_flip). The package is actively maintained with a recent release and has been stable since its early releases.
License in practice
BSD-2-Clause is a permissive license that allows commercial use, modification, and distribution with minimal restrictions—suitable for most projects.
Quickstart
pip install troposphere
from troposphere import Template, Ref
import troposphere.ec2 as ec2
t = Template()
instance = ec2.Instance("myinstance", ImageId="ami-951945d0", InstanceType="t1.micro")
t.add_resource(instance)
print(t.to_json())
Verify before relying
- Whether cfn_flip is required at runtime or only for optional output format conversion
- Scope and completeness of AWS resource type coverage relative to current CloudFormation service offerings
Package facts
| License | BSD-2-Clause permissive |
| Python support | Supports the current Python release >=3.8 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 1 packagecfn_flip |
| Maintenance | Actively maintained 90 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 1,281,350 / month, #4,116 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14 |
Evidence: troposphere-4.10.2-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 › “cloudformation json builder”
- troposphereTroposphere is a Python library that generates AWS CloudFormation…
- cfn-flipConverts AWS CloudFormation templates between JSON and YAML formats,…
- cfn-lintValidates AWS CloudFormation templates in YAML or JSON format against…
Give your agent the search over MCP, or paste the wish link into any chat.
More Build Tools packages
Provides reusable utilities for Python packaging interoperability, including version handling, specifiers, markers, requirements, tags, and metadata parsing according to standards like PEP 440 and PEP 425.
Wraps any iterable to display a real-time progress bar in the terminal or Jupyter notebook, showing iteration count, elapsed time, and estimated time remaining.
pip is the standard installer for Python packages, enabling you to download and install packages from the Python Package Index and other indexes into your Python environment.
Hatchling is a standards-compliant Python build backend that handles packaging, metadata, and distribution of Python projects when configured in a project's pyproject.toml file.
Generates Python gRPC service stubs and message classes from Protocol Buffer definitions, enabling developers to build gRPC clients and servers.
pre-commit is a framework for installing and running git hooks written in any language before commits are made, automating code quality and validation checks across multi-language projects.
Install it if your team needs consistent, automated validation at commit time.
See also aws-sam-translator · aws-cdk.aws-cloudformation · awacs · cfn-lint · aws-cdk.core · python-heatclient · aws-cdk.aws-ecs · aws-cdk.aws-ec2 · cfn-flip · aws-cdk-lib