Node.js Basics: What It Is and Getting Started
Welcome to the first part of our Node.js Jumpstart series for beginners! In this article, we'll cover the fundamental question: What is Node.js? We'll also get you up and running with your very first Node.js program. This is the starting point for your journey into server-side JavaScript.

What Exactly is Node.js?
Imagine JavaScript, the language you use to make websites interactive in a browser (like Chrome or Firefox), being able to run outside that browser. That's what Node.js does! Node.js is an environment that lets you run JavaScript code on a server, on your computer, or basically anywhere other than a web browser. How does it work?
- It uses Google's V8 engine: This is the same super-fast engine that powers Chrome. It takes your JavaScript code and turns it into machine code that the computer can understand quickly.
- It uses the libuv library: This library helps Node.js handle many tasks without waiting for each one to finish. This is key to its efficiency (we'll discuss how it does this in more detail in the next article on the Event Loop).
Why should you use Node.js?
- Speed: V8 makes your JavaScript run very fast.
- Efficiency: It's great at handling many connections or tasks at once without getting stuck.
- JavaScript Everywhere: If you already know JavaScript, you can use it for both the front-end (what users see in the browser) and the back-end (the server side).
- Massive Ecosystem: Node.js has npm (Node Package Manager), the world's largest software registry. This means thousands of ready-made tools and libraries you can easily add to your projects.
Quick side note:
If you’re already working on a team that uses Node.js, you might want to politely ignore my “somewhat professional” advice and just ask your teammates about their setup steps.
Node versions are constantly hitting End of Life (EoL) and getting replaced faster than most people's phone chargers, so many teams use a version manager like NVM (Node Version Manager) or NVM for Windows. Think of NVM as Git, but for easily managing your Node version.
Either way, definitely check with your team first to see how they like to run things—because nothing says “team player” like not nuking the dev environment on your first day.
Getting Started: Your First Node.js Program
Let's write the classic "Hello, World!" program in Node.js. This will confirm your installation is working and show you the basic command to run Node.js files.
Step 1: Install Node.js
Who am I kidding — if you're reading this, you already have Node installed and you've yelled at npm install at least once in your life.
If you haven't already, download and install Node.js from the official website: https://nodejs.org/. This also installs npm.
Step 2: Create a file
Open a simple text editor (like VS Code, Sublime Text, or even Notepad) and create a new file named hello.js
.
Step 3: Write the code
Type or paste this simple line into hello.js
:
console.log("Hello, World!");
Step 4: Run the program Open your computer's terminal or command prompt. Navigate to the folder where you saved hello.js. Then, type this command and press Enter:
node hello.js
Output:
Hello, World!
Congratulations! You've just run your first Node.js program.
Ready for the next step? Continue to the next article in this series: JavaScript Fundamentals: Variables (var, let, const).