Full-Stack Web Development with Next.js and NestJS
Build and ship a complete online grocery store — React and Next.js on the front, NestJS and PostgreSQL behind it.
This is the course everything else on this site builds towards. You write both halves of a real application and connect them properly, which is the part that tutorials almost always skip.
The front end is React with Next.js. The back end is NestJS with PostgreSQL and Prisma. Both are TypeScript, so one language covers the whole stack and the types travel between them.
The project is a working online grocery store for a neighbourhood kirana shop: catalogue, search, cart, checkout, payments, order tracking, delivery slots and an admin area for the owner. The sort of thing BigBasket does, at a scale one shop can actually run.
It is deliberately a real brief rather than a to-do list. Real briefs have stock that runs out mid-checkout, prices that change while an item sits in a cart, and customers who refresh at exactly the wrong moment. Those problems are the reason this course is worth taking, and they are why it is the longest one here.
Who this is for
- Developers who can write TypeScript and want to build whole products
- Front-end developers who want to own the back end too
- Back-end developers tired of waiting on somebody else for the UI
- Interns moving on to real client project work
What you need first
- Solid JavaScript and TypeScript. The TypeScript Foundation course is assumed throughout, not taught again.
- HTML and CSS to roughly the level of our Web UI Development Foundation course.
- SQL basics. The Database Foundation course covers far more than enough.
- Comfort with Git and the command line.
Tools you will use
By the end you can
- Build a React front end with the Next.js App Router, server and client components
- Build a NestJS back end with modules, dependency injection, guards and pipes
- Model and query PostgreSQL through Prisma, including migrations
- Design REST APIs with validation, useful errors and pagination
- Implement authentication, sessions and role-based access properly
- Handle money, stock and orders without a race condition losing you data
- Take payments through a gateway in test mode, verified by webhook
- Test both halves of the stack, including end to end
- Deploy the whole thing and know when it breaks
16 modules, 81 lessons
Work through these in order. Each lesson is short enough to finish in one sitting and ends with something to build, not a quiz.
- 1
How a Full-Stack Application Fits Together
The mental model first, so the rest of the course has somewhere to attach.
- The shape of a modern web applicationComing soon
- What runs where, and why it matters so muchComing soon
- HTTP, REST and the life of a requestComing soon
- Setting up the project you will build all courseComing soon
- 2
React Fundamentals
Enough React to build real interfaces, without the folklore.
- Components and JSXComing soon
- Props, and thinking in componentsComing soon
- State and useStateComing soon
- Events and controlled formsComing soon
- useEffect, and why you need it less than you thinkComing soon
- Lists, keys and rendering collectionsComing soon
- Composition over configurationComing soon
- 3
Next.js: Routing and Rendering
The framework that makes a storefront fast and findable.
- The App Router and file-based routingComing soon
- Server components versus client componentsComing soon
- Fetching data, caching and revalidationComing soon
- Layouts, loading and error statesComing soon
- Server actions, and forms without writing an API callComing soon
- Metadata and SEO for a storefront that must rankComing soon
- 4
Building the Interface
Making it look right and work for everybody, including on a cheap phone.
- Styling with TailwindComing soon
- A small component library you will actually reuseComing soon
- Responsive layouts for a real product gridComing soon
- Accessible forms and validation feedbackComing soon
- Client state: when you need it and what to useComing soon
- 5
NestJS Fundamentals
Structure, and what dependency injection actually buys you.
- Why NestJS, and what its structure is forComing soon
- ModulesComing soon
- Controllers and routingComing soon
- Providers and dependency injectionComing soon
- Pipes, filters and interceptorsComing soon
- Configuration, environments and secretsComing soon
- 6
The Data Layer
Prisma and PostgreSQL, from schema to query.
- Prisma: schema, client and migrationsComing soon
- Modelling the catalogueComing soon
- Relations in PrismaComing soon
- Queries, filtering and paginationComing soon
- Transactions, where they genuinely matterComing soon
- Seeding a database you can actually develop againstComing soon
- 7
REST APIs Done Properly
The difference between an API that works and one somebody else can use.
- Designing the endpoints before writing themComing soon
- DTOs and validationComing soon
- Errors a client can actually act onComing soon
- Pagination, filtering and sortingComing soon
- Versioning, and not breaking your own front endComing soon
- 8
Authentication and Authorisation
Getting the part wrong that you cannot afford to get wrong.
- Sessions, tokens, and what to use whenComing soon
- Registration and loginComing soon
- Storing passwords properlyComing soon
- Guards and role-based accessComing soon
- Protecting pages and actions on the front endComing soon
- 9
Connecting the Two Halves
The seam between front and back, which is where most bugs live.
- Sharing types between front end and back endComing soon
- Loading states, errors and optimistic updatesComing soon
- Handling failure without showing a blank screenComing soon
- CORS, cookies and the security basicsComing soon
- 10
Kirana Store: Planning
What the shop actually needs, decided before any code is written.
- The brief: what a kirana shop actually needs onlineComing soon
- From a brief to user storiesComing soon
- Designing the data modelComing soon
- Deciding the architecture, and writing down whyComing soon
- 11
Kirana Store: Catalogue and Search
Products, categories and the units a grocery shop actually sells in.
- Products, categories, units and pricingComing soon
- The catalogue APIComing soon
- The storefront and product gridComing soon
- Search, filters and sensible defaultsComing soon
- Product images, and why they will slow you downComing soon
- 12
Kirana Store: Cart and Checkout
The hardest part of any shop, and the part most tutorials fake.
- Modelling a cart that survives a refresh and a loginComing soon
- The cart interfaceComing soon
- Stock: the hard problem nobody warns you aboutComing soon
- The checkout flowComing soon
- Addresses and delivery slotsComing soon
- 13
Kirana Store: Orders and Admin
What happens after the customer pays, and the screens the owner lives in.
- Orders, statuses and the state machineComing soon
- Order history and trackingComing soon
- The shop owner's admin areaComing soon
- Managing inventory and pricesComing soon
- Telling the customer what is happeningComing soon
- 14
Payments
Taking money, in test mode, without trusting anything the browser tells you.
- How an online payment actually worksComing soon
- Integrating a payment gateway in test modeComing soon
- Webhooks, and never trusting the browserComing soon
- Failed payments, retries and refundsComing soon
- 15
Testing the Whole Stack
Enough tests to change the code without fear, and no more.
- What to test, and what not to bother withComing soon
- Unit testing NestJS servicesComing soon
- Testing the API end to endComing soon
- Testing React componentsComing soon
- End-to-end tests with PlaywrightComing soon
- 16
Shipping It
Getting it live, and knowing when it breaks at two in the morning.
- Environments, secrets and configurationComing soon
- Deploying the front endComing soon
- Deploying the API and the databaseComing soon
- Logging, errors and knowing when it breaksComing soon
- Going live, and the checklist to run firstComing soon
Learning this with a mentor is faster
Our internship programme is free and fully remote. You get this curriculum, real project work, and code review from working developers.