Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
Python FastAPI: Complete Course - Build a Full-Stack Web App
Rating: 4.4 out of 5(6 ratings)
45 students

Python FastAPI: Complete Course - Build a Full-Stack Web App

Build, test, and deploy a full-stack FastAPI app with Pydantic, SQLAlchemy, PostgreSQL, JWT auth, and Docker.
Created byCorey Schafer
Last updated 5/2026
English

What you'll learn

  • Build a complete full-stack web application with FastAPI, including a REST API, HTML frontend with Jinja2, and JavaScript-powered forms
  • Design robust APIs using Pydantic schemas, SQLAlchemy models, async routes, and well-organized modules with APIRouter
  • Implement secure authentication and authorization with JWT, password reset flows, file uploads with image processing, and pagination
  • Deploy production-ready apps using PostgreSQL, Alembic migrations, AWS S3, automated testing with Pytest, Nginx, SSL, and Docker

Course content

9 sections19 lectures14h 22m total length
  • Getting Started - Web App + REST API23:10

    In this series of lectures, we'll be learning how to build a full-featured web application from the ground up using the FastAPI framework in Python. We'll build both a JSON API for programmatic access and HTML pages for users to browse in the browser. Throughout the series, we'll set up a database with SQLAlchemy, create Pydantic models for data validation, and implement complete CRUD operations. We'll add user registration and login with secure password hashing and JWT tokens, handle file uploads for profile pictures, use background tasks for sending emails, and organize our code properly with routers.

    In this first lecture, we'll keep things simple. We'll install FastAPI, create a basic application, build a couple of routes that return JSON, run the app from the command line, and explore FastAPI's automatic documentation. Then we'll add some dummy data, create an API endpoint, and preview returning HTML responses.

  • HTML Frontend for Your API - Jinja2 Templates36:49

    In this lecture, we'll be learning how to use Jinja2 templates to create an HTML frontend for our API. Templates allow us to serve proper HTML pages to users while keeping our JSON endpoints intact for the backend API. We'll cover setting up Jinja2Templates, passing data to templates, using Jinja2 syntax for loops and conditionals, implementing template inheritance with a layout file, adding Bootstrap for styling, and configuring static files for CSS and images. By the end of this lecture, we'll have a nicely styled blog homepage that displays our posts.

Requirements

  • Basic Python Programming (variables, functions, and classes)

Description

In this course, we'll be learning how to build a full-featured web application from the ground up using the FastAPI framework in Python. It covers everything from creating your first route all the way through deploying a production-ready application with a custom domain. We'll build both a JSON API for programmatic access and HTML pages that users can browse in the browser, so you'll come away knowing how to use FastAPI for either purpose.

Along the way, we'll set up a database with SQLAlchemy, write Pydantic models for request and response validation, and implement complete CRUD operations. We'll add user registration and login with secure password hashing and JWT authentication, protect routes by verifying the current user, and handle file uploads with image processing and validation. We'll convert our app to async, organize our code with routers, build out frontend forms that connect to the API with JavaScript, and add pagination, password reset flows with background email tasks, and database migrations with Alembic. Toward the end, we'll move from SQLite to PostgreSQL, move our file storage from local disk to AWS S3 with Boto3, write tests with Pytest, and finally deploy the application two different ways... first to a VPS with Nginx and SSL, and then with Docker to a serverless container platform.

Technologies covered:

  • FastAPI

  • Pydantic

  • SQLAlchemy

  • Jinja2 templates

  • JavaScript (Fetch API)

  • JWT authentication

  • Pillow (image processing)

  • Background tasks with aiosmtplib

  • PostgreSQL

  • Alembic (database migrations)

  • AWS S3 / Boto3

  • Pytest

  • Nginx and Let's Encrypt SSL

  • Docker (serverless deployment)

Whether you're new to FastAPI or have used it for small projects and want to see how a real production application comes together, this course will give you a solid foundation.

Who this course is for:

  • Python developers who want to learn how to build modern web applications and APIs with FastAPI, including beginners getting into web development for the first time and experienced developers looking to add FastAPI to their toolkit.