Python learning hub
Python is a general-purpose language that reads almost like plain English. It is used for scripting and automation, web back ends, data analysis and machine learning, and it is one of the most common first languages.
The guides here follow the order most beginners need: install Python and set up a clean project, learn the built-in data structures, work with files, and then call an API. Each guide has code you can run.
A suggested path
- 1
Set up
Install Python, run your first program, and keep each project's packages separate with a virtual environment.
Related guide: How to Install Python and Run Your First Program (Windows, macOS, Linux) → - 2
Learn the building blocks
Know when to use a list, tuple, dictionary or set; most Python code is built from these.
Related guide: Python Lists, Tuples, Dictionaries and Sets: When to Use Each → - 3
Work with data
Read and write files, parse CSV and JSON, and fetch data from web services.
Related guide: Reading and Writing Files in Python: open(), with, CSV and JSON → - 4
Choose a direction
Web with Flask or Django, data with pandas, or scripts that automate your own tasks. Pick one and build a small project.
All Python guides (5)
Getting started
Install Python and set up a project.
Core language
Lists, dictionaries and the other built-in types.
Files and APIs
Reading files and calling web services.
Free tools for Python
They run in your browser, so what you paste is not uploaded.
- JSON Formatter & ValidatorFormat, validate and minify JSON in your browser. Shows the exact line and column of any error.
- Regex TesterTest JavaScript regular expressions live: see matches highlighted, capture groups and a replace preview.
- JSON, YAML & CSV ConverterConvert JSON to YAML, YAML to JSON, JSON to CSV and CSV to JSON, with nested data, delimiters and type detection handled.
- Unix Timestamp ConverterConvert Unix timestamps to dates and dates to timestamps in any time zone. Detects seconds, milliseconds, microseconds and nanoseconds.
- UUID GeneratorGenerate random (v4) or time-ordered (v7) UUIDs in bulk, and check the version of any UUID.
- Hash Generator (MD5, SHA-256, SHA-512)Generate MD5, SHA-1, SHA-256, SHA-384, SHA-512 and CRC-32 hashes of text or files, with HMAC and a hash checker.
- Cron Expression GeneratorBuild and understand cron schedules: plain-English meaning, the next run times and a ready crontab line.
- Text Diff Checker (Compare Two Texts)Compare two pieces of text or code side by side and see added, removed and changed lines, with a copyable patch.
Common questions
Is Python good for beginners?
Yes. The syntax is simple, error messages are readable, and you can do useful things quickly. Most people can write small scripts within a few weeks of regular practice.
Which Python version should I install?
Install the latest stable Python 3 release. Python 2 reached its end of life in 2020 and should not be used for anything new.
Why do I need a virtual environment?
It keeps the packages for each project separate, so installing a library for one project cannot break another. Our virtual environment guide shows how to create and use one.