argcomplete
Bash tab completion for argparse
Decision gist · record as of 2026-08-14
Yes. Argcomplete is actively maintained, has no known vulnerabilities, carries a permissive license, and requires no runtime dependencies. It integrates seamlessly into existing argparse-based CLIs with minimal code changes. Install it if you want to add professional-grade tab completion to your Python command-line tools.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later.
- Bash or zsh shell required for tab completion to function; limited support exists for other shells.
- Low install friction with a single wheel distribution.
License · maintenance · safety
Apache Software License (permissive) — Licensed under Apache Software License (permissive), allowing commercial and private use with minimal restrictions.
last release 2026-08-06 (8 days) · last repo commit 2026-08-08 · 1,576 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 84,820,908 downloads/mo, #398 on PyPI
Alternatives
Verify before relying
pip install argcomplete
#!/usr/bin/env python
# PYTHON_ARGCOMPLETE_OK
import argcomplete, argparse
parser = argparse.ArgumentParser()
argcomplete.autocomplete(parser)
args = parser.parse_args()- Whether custom completer functions can handle async or network-based completions without blocking the shell.
- Performance characteristics when used with very large argument sets or deeply nested subparsers.
What it is and what it does
Argcomplete adds intelligent tab completion to Python command-line applications that use argparse. When a user presses Tab in bash or zsh, argcomplete intercepts the command, runs your program to collect available completions, and displays them. It works by injecting a marker (PYTHON_ARGCOMPLETE_OK) and a single function call (argcomplete.autocomplete()) into your script before argument parsing begins.
The package supports both static completions (from argparse choices) and dynamic ones (from custom completer functions). Completers receive context about what the user has typed so far, the current parser state, and parsed arguments up to that point, allowing them to suggest contextual options. For zsh, completers can return descriptions alongside suggestions. Registration is done either per-application using register-python-argcomplete or globally via activate-global-python-argcomplete.
Use it for
- Enable tab completion for a CLI tool with many subcommands or options without manual shell script maintenance.
- Provide dynamic completions that query a remote API or database based on what the user has typed so far.
- Reduce user friction when working with complex command-line applications by suggesting valid argument values.
- Share the same completion logic across bash and zsh without writing shell-specific code.
- Complete file paths, environment variables, or other context-aware values based on the current parse state.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Argcomplete is actively maintained, has no known vulnerabilities, carries a permissive license, and requires no runtime dependencies. It integrates seamlessly into existing argparse-based CLIs with minimal code changes. Install it if you want to add professional-grade tab completion to your Python command-line tools.
Install
argcomplete on PyPI
Before you install
Low install friction with a single wheel distribution. Actively maintained with a release 8 days ago; the repository shows 1576 stars and recent activity, indicating solid ongoing support.
Requires Python 3.10 or later. Bash or zsh shell required for tab completion to function; limited support exists for other shells.
License in practice
Licensed under Apache Software License (permissive), allowing commercial and private use with minimal restrictions.
Quickstart
pip install argcomplete
#!/usr/bin/env python
# PYTHON_ARGCOMPLETE_OK
import argcomplete, argparse
parser = argparse.ArgumentParser()
argcomplete.autocomplete(parser)
args = parser.parse_args()
Verify before relying
- Whether custom completer functions can handle async or network-based completions without blocking the shell.
- Performance characteristics when used with very large argument sets or deeply nested subparsers.
Package facts
| License | Apache Software License permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 8 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 84,820,908 / month, #398 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/StableEnvironment :: ConsoleIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseOperating System :: MacOS :: MacOS XOperating System :: POSIXProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPyTopic :: Software DevelopmentTopic :: Software Development :: Libraries :: Python ModulesTopic :: System :: ShellsTopic :: Terminals |
Evidence: argcomplete-3.7.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 › “command line argument completion”
- argcompleteProvides bash and zsh tab completion for Python applications using…
- colcon-argcompleteAdds shell command-line completion to colcon build tool commands…
- click-completionAdds shell completion support (Bash, Zsh, Fish, PowerShell) to Click…
Give your agent the search over MCP, or paste the wish link into any chat.
More Software Development packages
Provides backported and experimental type hints for Python 3.9+, allowing use of newer typing features on older Python versions and enabling early experimentation with type system PEPs before they enter the standard library.
NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.
FastAPI is a Python web framework for building REST APIs using type hints, with automatic request validation, serialization, and interactive API documentation.
Provides a way to document function parameters, class attributes, return types, and variables inline using Python's `Annotated` type hint syntax instead of traditional docstrings.
Typer builds command-line applications from Python functions using type hints, automatically generating help text, argument parsing, and shell completion.
Install it if you are building CLIs in Python.
Distlib provides low-level packaging utilities for building, distributing, and managing Python software—including metadata handling, version specifiers, wheel support, script installation, and dependency resolution.
See also shtab · colcon-argcomplete · click-completion · argparse-addons · fancycompleter · auto-click-auto · tabcompleter · typed-argument-parser · rich-argparse · guacamole