Node.js & Express
Node.js and Express Backend Development
Build and operate a real backend REST API: the Node runtime model, Express routing and middleware, validation, structured error handling, security fundamentals, and automated testing.
Helpful before you begin (optional -- you can start this course now): React Application Development
Who it's for
Developers comfortable with JavaScript (and ideally React) who want to build and operate a real backend API, not just consume one, and understand what actually happens between a request arriving and a response leaving.
What you'll be able to do
- Explain Node's event-loop model and convert between callback, Promise, and async/await styles safely
- Structure a real Express application with modular routing and a correct middleware pipeline
- Validate untrusted input and implement centralized, structured error handling
- Design REST resources and status codes, and manage configuration and logging safely
- Implement correct authorization boundaries without building an unsafe auth system from scratch
- Separate business logic into testable services and add a real automated test suite
Not started — 14 lessons, no account required.
Start this coursePractice this course →Add to a study plan →Interview questions →
Node.js runtime foundations
The event loop, module systems, and the three faces of asynchronous JavaScript in Node.
- 19 min
The Node.js Runtime Model: Event Loop and Non-Blocking I/O
Why Node can handle thousands of concurrent connections on one thread — and the one mistake (blocking that thread) that defeats the entire model.
- 17 min
CommonJS vs ES Modules, npm, and Dependency Management
Node's two module systems, why they don't mix carelessly, and what npm actually manages beyond just downloading packages.
- 20 min
Asynchronous Programming: Callbacks, Promises, and Async/Await
Three syntaxes for the same underlying idea — and the one mistake (an unawaited or unhandled promise) that silently swallows errors in a real server.
Building an Express app
Route matching, the middleware pipeline, and the three sources of request data.
- 28 min
Express Application Structure and Routing
How Express matches an incoming request to the right handler, and setting up a real, modularly-routed Express server on your own machine.
- 19 min
Middleware: The Request Pipeline
Every Express request flows through a pipeline of functions, each deciding whether to pass control forward. Understanding next() is the entire mental model.
- 18 min
Request Parameters, Query Strings, and Bodies
Three different places data arrives from in a request, each meaning something different — mixing them up is a common source of confusing bugs.
Designing a real API
Validating untrusted input and designing REST resources and status codes deliberately.
- 30 min
Input Validation and Rejecting Bad Requests
Never trust a request body. Add real validation and a centralized error-handling middleware to your local Express API, so bad input is rejected consistently and safely everywhere.
- 19 min
REST Resource Design and HTTP Status Behavior
Designing an API's resources and status codes from the implementer's side — the same conventions this curriculum's testing courses teach testers to verify.
Errors, logging, and configuration
Structured errors, safe logging, and failing fast on broken configuration at startup.
- 20 min
Structured Errors: Operational vs. Programmer Errors
Not every thrown error deserves the same response. Distinguishing an expected, handleable failure from a genuine bug changes what's safe to tell the client.
- 18 min
Environment Configuration and Safe Logging
Configuration belongs outside your code, not hardcoded inside it — and logs are a real, common place secrets accidentally leak.
- 18 min
Configuration Validation and Startup Failures
A server that starts successfully with broken configuration is worse than one that refuses to start at all — failing fast, loudly, at startup is a deliberate design choice.
Security and testing
Correct authorization boundaries and a real, isolated automated test suite.
- 22 min
Security Fundamentals and Authentication Boundaries
Baseline server-side security every API needs, and where authentication responsibility genuinely ends — without building an unsafe, from-scratch auth system.
- 30 min
Automated Testing for Routes and Services
Test the pieces of a real Express API the way this curriculum's testing courses teach — separating logic from routing so most of it never needs a running server at all.
Operational readiness
Graceful shutdown and health checks — what it takes to run a service, not just write one.
Where to go next
Optional -- these build well on what you just learned, but any course can come next.