Before touching NestJS, you need to master TypeScript, OOP concepts, dependency injection, and the basics of HTTP and REST APIs. In this episode you'll also set up Node.js LTS, an editor, the Nest CLI, and the local database needed to follow the entire series.

Welcome to the Learning NestJS series! This series will take you from mastering NestJS — the modern backend framework built on Node.js and TypeScript — from foundational concepts all the way to production readiness. There are 24 episodes in total, arranged into six phases.
But before touching nest, there are a few basic skills and software tools you must have. Why are these pre-requisites important? Because NestJS is built on top of TypeScript and adopts an Angular-style modular architecture. If you don't yet understand what decorators or dependency injection are, almost every upcoming episode will feel confusing.
Episode 0 is your roadmap: we'll make sure your basic skills are in place, set up your Node.js environment, install the Nest CLI, and verify the whole setup before you write your first line of code.
NestJS is written entirely in TypeScript and compiled to JavaScript. You should be comfortable with modern syntax like async/await, class, interface, and generic types. The most crucial part is understanding decorators — a TypeScript feature that is the foundation of almost every NestJS feature such as @Module and @Controller.
function LogClass(constructor: Function): void {
console.log("Class dimuat:", constructor.name);
}
@LogClass
export class UserService {
findAll(): string[] {
return ["Arman", "Budi"];
}
}The @LogClass example above shows how decorators are used to add behavior. In NestJS, decorators like @Controller and @Get work the same way.
NestJS adopts the object-oriented programming paradigm strictly. You must understand the concepts of class, inheritance, encapsulation, and most importantly: dependency injection. This is a pattern where an object does not create its own dependencies, but receives them from outside — usually through its constructor.
class DatabaseService {
connect(): string {
return "terhubung";
}
}
class UserService {
constructor(private readonly db: DatabaseService) {}
}Notice how UserService receives DatabaseService through its constructor, instead of creating it itself. This is the core of dependency injection, which we'll dig into in depth in episode 5.
NestJS runs on top of Express or Fastify by default. You need to understand HTTP concepts: the GET, POST, PUT, DELETE, PATCH methods; status codes like 200, 201, 400, 404; and how a REST API organizes resources through URLs. A basic understanding of architecture layers such as controller, service, and repository will also help a lot.
The main requirement for NestJS is Node.js LTS — as of the writing of this series, versions 20 and 22 are the best choices. You can use npm, yarn, or pnpm as your package manager; this series uses npm. First, verify the Node and npm versions on your system:
node --version
npm --versionThe output of node --version should show version 20 or newer. If you don't have it yet, use nvm (Node Version Manager) to install the LTS version.
The most popular editor for NestJS is VS Code. Install the following extensions for comfort: TypeScript (automatic from VS Code), ESLint, Prettier, and NestJS Snippets. Alternatives like WebStorm and Neovim with the TypeScript LSP are also very capable.
The Nest CLI is the official tool for creating and managing NestJS projects. Install it globally:
npm install -g @nestjs/cliMake sure the nest --version command prints a CLI version after installation. For the database, prepare at least one of: PostgreSQL, MySQL, MongoDB, or SQLite. SQLite is the lightest choice for practice because it doesn't require a server.
The cleanest way to manage Node.js on Linux and macOS is through nvm:
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
nvm install --lts
nvm use --ltsWindows users can use nvm-windows or the official installer from nodejs.org. When you're done, run node --version to make sure the LTS version is active.
For the closest experience to production, run PostgreSQL via Docker:
docker run --name nestjs-db -e POSTGRES_PASSWORD=rahasia -p 5432:5432 -d postgres:16If Docker isn't available on your machine, SQLite is enough for episodes 6 and 10 — no extra installation needed besides the npm packages later on.
Before moving on, make sure everything is ready by running a full verification:
node --version
npm --version
nest --version
docker --versionIf all commands return their respective versions, your environment is ready. The full checklist:
npm is installed alongside it.nest --version.Episode 0 prepares all the technical foundations before you write NestJS code: TypeScript skills and OOP concepts, dependency injection, HTTP understanding, Node.js LTS, the Nest CLI, and a local database. All of these elements will be used throughout the rest of the series.
Key takeaways:
npm install -g @nestjs/cli.node --version and nest --version before you begin.In the next episode 1 we'll discuss the history, background, and why you need NestJS — starting from the evolution of the Node.js backend, the birth of NestJS as an architecture solution, to its comparison with Express and other frameworks. Make sure your environment is ready, because the Learning NestJS journey has just begun!