Node Introduction

What is Node.js?

Node.js is an open source runtime that lets you run JavaScript on the server. It is built on Chrome's V8 engine and is designed for fast, event-driven applications.

Instead of waiting for one task to finish before starting the next, Node.js handles many operations asynchronously. That makes it a strong fit for APIs, real-time apps, and tools that spend a lot of time waiting on network or file operations.

Why Learn Node.js?

Common Use Cases

Simple Server Example

const http = require('http');

const server = http.createServer((req, res) => {
    res.writeHead(200, { 'Content-Type': 'text/plain' });
    res.end('Hello from Node.js');
});

server.listen(3000, () => {
    console.log('Server running on http://localhost:3000');
});

This example shows the basic Node.js pattern: receive a request, prepare a response, and send it back.

What To Remember

What To Learn Next

Once you understand this introduction, the next step is learning how to install Node.js, run npm, and create a small Express app.