--- id: types-psutil version: "7.2.2.20260518" license: Apache-2.0 license_treatment: permissive maintenance: active --- # types-psutil — Typing stubs for psutil License: permissive · Maintenance: active · Downloads: 7.9M/mo ## What it is and what it does types-psutil is a type stub package that provides type annotations for psutil, the system and process monitoring library. It allows static type checkers—mypy, pyright, and others—to understand and validate code that imports and uses psutil, catching type errors at development time rather than runtime. The package is maintained as part of typeshed, the standard repository of type stubs for the Python ecosystem. This version targets psutil 7.2.2 and has been tested with mypy 2.1.0 and pyright 1.1.409. Installation adds no runtime overhead; it only affects type checking. It requires Python 3.10 or later. Use it for: - Enable mypy or pyright to type-check code that calls psutil functions for CPU, memory, or process information. - Catch incorrect argument types or missing attributes when working with psutil.Process or psutil.sensors in an IDE with inline type checking. - Maintain type safety in system administration or monitoring scripts that rely on psutil's API. - Integrate psutil into a larger typed codebase without losing type information at module boundaries. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Provides type annotations for the psutil library, enabling type checkers like mypy and pyright to validate code that uses psutil for system and process monitoring. Yes, if you use psutil and run a type checker. It is a lightweight, actively maintained stub package with no runtime dependencies and permissive licensing. Install it alongside psutil to get accurate type hints during development. No reason not to if you are already using a type checker. ## Install pip install types-psutil uv add types-psutil poetry add types-psutil ## Installing types-psutil Before you install: Low friction installation with no runtime dependencies. Maintained as part of the typeshed project with active updates; last release 88 days ago. License in practice: Licensed under Apache-2.0 (permissive), allowing use in most projects without significant legal constraints. Quickstart: pip install types-psutil # In your code, type checkers will now understand psutil imports: import psutil proc: psutil.Process = psutil.Process() Requires Python 3.10 or later; type checking requires a compatible type checker like mypy 2.1.0 or pyright 1.1.409. Verify before relying: - Whether types-psutil stays synchronized with psutil releases beyond 7.2.2 - Coverage completeness for all psutil APIs in the current version ## Package facts - License: Apache-2.0 (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 7.9M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags psutil type stubs, psutil type hints, type checking psutil, mypy psutil annotations, psutil typing support, pyright psutil stubs, psutil type annotations, type-stubs, type-checking [View on SkillFed](https://skillfed.io/packages/types-psutil) · [View on PyPI](https://pypi.org/project/types-psutil/)