The Python standard library contains over 200 modules. Being an open-source programming language everyone can contribute to Python by creating more packages, libraries and modules. But some modules comes preinstalled with Python which collectively is known as the Python standard library. So in this article, I will take you through a list of all modules in Python.
List of All Modules in Python
All the Python modules mentioned below are those modules that come preinstalled in the Python standard library. To become a Python developer you don’t need to learn all these modules but you should know which module is used for which task. So below is a list of all modules in Python.
Python Modules | The Usage of Python Modules |
---|---|
aifc | Used to read and write audio files in AIFF or AIFC format. |
argparse | Commandâline option and argument parsing library. |
array | Spaceâefficient arrays of uniformly typed numeric values. |
asynchat | Support for asynchronous command/response protocols. |
asyncio | Asynchronous I/O, event loop, coroutines, and tasks |
asyncore | A base class for developing asynchronous socketâhandling services. |
atexit | Register and execute cleanup functions. |
audioop | Manipulate raw audio data. |
base64 | RFC 3548: Base16, Base32, Base64 Data Encodings; Base85, and ASCII85. |
binascii | Tools for converting data to and from various ASCIIâencoded binary representations. |
binhex | Encode and decode files in binhex4 format. |
bisect | Array bisection algorithms for binary searching. |
bz2 | Interfaces for bzip2 compression and decompression. |
calendar | Functions for working with calendars. |
cmath | Mathematical functions for complex numbers. |
cmd | Build lineâoriented command interpreters. |
collections | Container data types. |
configparser | Configuration file parser. |
contextlib | Utilities for withâstatement contexts. |
copy | Shallow and deep copy operations. |
csv | Write and read tabular data to and from commaâdelimited data files. |
ctypes | A foreign function library for Python. |
datetime | Basic date and time operations. |
dbm | Interfaces to various keyâvalue database formats. |
decimal | Implementation of the General Decimal Arithmetic Specification. |
doctest | Test snippets of code appearing within docstrings. |
fractions | Rational numbers. |
functools | Higherâorder functions and operations on callable objects. |
gettext | Multilingual internationalization services. |
glob | UNIX shell-style pathname pattern expansion. |
hashlib | Secure hash and message digest algorithms. |
html.parser | A simple parser that can handle HTML and XHTML. |
http | Package supporting the use of HTTP including client, server, and cookie management. |
http.server | HTTP server and request handlers. |
itertools | Functions creating iterators for efficient looping. |
json | Encode and decode the JSON data format. |
locale | Internationalization services. |
logging | Flexible event logging for applications |
math | Mathematical functions |
os | Miscellaneous operating system interfaces. |
os.path | Provides helper functions for manipulating and testing file paths. |
pdb | A debugger for interactive Python interpreters. |
pickle | Convert Python objects to streams of bytes and back. |
pwd (UNIX) | The password database. |
queue | A queue class suitable for communicating between threads. |
re | Regularâexpression operations. |
shelve | Python object persistence. |
shlex | Simple lexical analysis for UNIX shell-like languages. |
socket | Lowâlevel networking interface. |
socketserver | A framework for network servers. |
sqlite3 | A DBâAPI 2.0 implementation using SQLite 3.x. |
tkinter | Interface to Tcl/Tk for graphical user interfaces |
turtle | An educational framework for developing simple graphics applications. |
urllib | Package for processing URLs including requests, responses, errors, and so on. |
xml | Package containing XML processing modules |
zipfile | Read and write zipâformat archive files. |
Also, Read – Python Projects with Source Code.
So this was the list of all the modules in the Python programming language that you should know as a Python developer. You can explore more about all these modules from here. I hope you liked this article, feel free to ask your valuable questions in the comments section below.