python

    python/mypy

    Optional static typing for Python

    20.7K stars
    3.4K forks
    20.7K GitHub watchers
    Updated Nov 2, 2026
    View on GitHub

    Build with Backblaze B2

    SDKs, agent skills, IDE extensions, and reference pipelines from Backblaze Labs. All open source.

    Explore Backblaze Labs

    Loading star history...

    Where it stands

    Rank, growth pace and release cadence relative to everything GStars tracks.

    The project lists 412 contributors on GitHub.

    Use Cases & Benefits

    • Provides optional static type checking for Python programs using type hints.
    • Enables early detection of type-related errors without running the code, improving code reliability and maintainability.
    • Use for gradually adding static typing to existing Python codebases to improve code quality incrementally.
    • Use for integrating static type checks into Python development workflows with popular IDEs and editors.
    • Use for speeding up type checking in large projects by running mypy in daemon mode for incremental analysis.

    Should you depend on it?

    License terms, project hygiene and risks, from GitHub metadata and GStars' snapshots.

    License

    Other

    GitHub could not identify this license; read the LICENSE file before depending on it.

    Community files

    • README: present
    • Contributing guide: present
    • Code of conduct: present

    Watch-outs

    • License not identified by GitHub; read the LICENSE file before depending on it.
    • No GitHub releases; pin a commit or tag instead of a release.

    General guidance from repository metadata, not legal advice. How we score

    From the README

    We are always happy to answer questions! Here are some good places to ask them:

    If you're just getting started, the documentation and type hints cheat sheet can also help answer questions.

    Mypy is a static type checker for Python.

    Type checkers help ensure that you're using variables and functions in your code correctly. With mypy, add type hints (PEP 484) to your Python programs, and mypy will warn you when you use those types incorrectly.

    Python is a dynamic language, so usually you'll only see errors in your code when you attempt to run it. Mypy is a static checker, so it finds bugs in your programs without even running them!

    Here is a small example to whet your appetite:

    Adding type hints for mypy does not interfere with the way your program would otherwise run. Think of type hints as similar to comments! You can always use the Python interpreter to run your code, even if mypy reports errors.

    Mypy is designed with gradual typing in mind. This means you can add type hints to your code base slowly and that you can always fall back to dynamic typing when static typing is not convenient.

    Mypy has a powerful and easy-to-use type system, supporting features such as type inference, generics, callable types, tuple types, union types, structural subtyping and more. Using mypy will make your programs easier to understand, debug, and maintain.

    Excerpt from the python/mypy README on GitHub (NOASSERTION license). © its authors.Read the full README on GitHub

    Daily snapshots

    Stars gained per day, and how forks and open issues moved, from GStars' daily snapshots

    Forks

    3.4K+94

    Open issues

    3.2K+73

    Compared with peers in Developer Tools

    Fastest-growing repositories GStars tracks in this cohort for the week of Nov 8, by 7-day star growth

    python/mypy compared with Developer Tools repositories by stars, 7-day star growth, health score and last release
    RepositoryStars+7dHealthLast release
    stablyai/orca121.4K+6.7K75today
    DietrichGebert/ponytail188.4K+4.4K7512 days ago
    affaan-m/ECC300.8K+4.3K7540 days ago
    herdrdev/herdr50.0K+2.1K7527 days ago
    max-sixty/worktrunk12.4K+1.9K7521 days ago
    python/mypy20.7K—45—
    Category median121.4K+4.3K75—

    Also by python

    Other repositories from this maintainer that GStars tracks

    Discover Repositories

    Search across tracked repositories by name or description