The Python standard library

This library reference manual describes the standard library distributed with Python. It also describes some of the optional components that are commonly included in Python distributions.

Elsewhere, A Referência da Linguagem Python describes the exact syntax and semantics of the Python language, and Referência da bibliotecas embutidas do Python describes the built-in functions.

Python’s standard library is extensive, offering a wide range of facilities as indicated by the long table of contents listed below. The library contains built-in modules (written in C) that provide access to system functionality such as file I/O that would otherwise be inaccessible to Python programmers, as well as modules written in Python that provide standardized solutions for many problems that occur in everyday programming. Some of these modules are explicitly designed to encourage and enhance the portability of Python programs by abstracting away platform-specifics into platform-neutral APIs.

Os instaladores do Python para a plataforma Windows geralmente incluem toda a biblioteca padrão e muitas vezes também incluem muitos componentes adicionais. Para sistemas operacionais semelhantes a Unix, o Python é normalmente fornecido como uma coleção de pacotes, portanto, pode ser necessário usar as ferramentas de empacotamento fornecidas com o sistema operacional para obter alguns ou todos os componentes opcionais.

Além da biblioteca padrão, há uma coleção ativa de centenas de milhares de componentes (de programas e módulos individuais a pacotes e frameworks de desenvolvimento de aplicativos inteiros), disponíveis no Python Package Index.