--- id: decompyle3 version: "3.9.3" license: GPL3 license_treatment: copyleft maintenance: active --- # decompyle3 — Python cross-version byte-code decompiler License: copyleft · Maintenance: active · Downloads: 286.1K/mo ## What it is and what it does Decompyle3 is a native Python decompiler that converts compiled Python bytecode (.pyc and .pyo files) back into human-readable source code. It accepts bytecode from Python 3.7 onwards and is a reworking of the uncompyle6 project, addressing control-flow detection issues by refactoring grammar and adding more specific markers in the instruction stream. The tool runs as a command-line utility and can optionally verify the syntax of decompiled output. The package depends on click for CLI handling, spark-parser for grammar-based parsing, and xdis for cross-version bytecode disassembly. It is actively maintained and has no known security vulnerabilities. The author acknowledges numerous decompilation bugs exist (as with all CPython decompilers) and notes that as Python optimization increases, decompilation becomes harder; the tool does not currently support obfuscated code, Cython, MicroPython, or Windows EXE extraction. Use it for: - Recover source code from compiled Python packages when original source is unavailable or lost - Analyze and audit third-party Python bytecode for security review or reverse-engineering - Debug compiled Python applications by examining the decompiled bytecode logic - Extract and study Python code from legacy or archived .pyc files for documentation or migration - Test and validate decompilation correctness against Python's own test suite ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Decompyle3 translates Python bytecode back into equivalent Python source code for versions 3.7 and later, enabling reverse-engineering and analysis of compiled Python files. Yes, if you need to decompile Python 3.7+ bytecode and accept the GPLv3 copyleft constraint. The tool is actively maintained, has low install friction, and carries no known vulnerabilities. Be aware that decompilation is imperfect—the author documents numerous known bugs and acknowledges that control-flow detection remains incomplete. Use the --syntax-verify option to validate output, and cross-check results with other decompilers when accuracy is critical. ## Install pip install decompyle3 uv add decompyle3 poetry add decompyle3 ## Installing decompyle3 Before you install: Low friction installation with three runtime dependencies (click, spark-parser, xdis). Active maintenance with recent commits and no known vulnerabilities. Last release was 317 days ago; repository shows ongoing development. License in practice: Licensed under GPLv3 (copyleft). Any derivative work or distribution must also be open-source under GPLv3; proprietary use or closed-source redistribution is not permitted. Quickstart: pip install decompyle3 decompyle3 compiled-python-file.pyc For syntax verification: decompyle3 --syntax-verify compiled-python-file.pyc Requires Python 3.7 or 3.8 to run; can only decompile bytecode from Python 3.7 onwards. Does not handle obfuscated code, Cython, MicroPython, or Py2EXE executables. Verify before relying: - Extent of known decompilation bugs and their frequency in real-world bytecode - Whether decompilation accuracy varies significantly across Python 3.7–3.13 versions - Performance characteristics when handling large or complex bytecode files ## Package facts - License: GPL3 (copyleft) - Python support: unspecified - Install friction: low - Maintenance: active - Downloads: 286.1K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags python bytecode decompiler, decompile pyc files, reverse engineer python bytecode, python source code recovery, bytecode to source code, cross-version python decompiler, pyc file decompilation, bytecode-analysis, reverse-engineering, cli-tool [View on SkillFed](https://skillfed.io/packages/decompyle3) · [View on PyPI](https://pypi.org/project/decompyle3/)