#2: Node.js First Steps :: NodeCasts: Free Node.js Screencasts

Episode 2: Getting Started with Node.js

Published Aug 6, 2026 · 7:30 · 7 comments

This screencast walks you through installing Node.js on Linux, Mac, and Windows, then shows how to run several Node versions side by side using NVM. It wraps up by building a small HTTP server in Node.js.

Download WebM (12 MB) Download MP4 (24 MB)

Show Notes

This episode runs on Node.js v0.8.5. Grab the matching downloads and consult the documentation.

Setting Up Your Environment

Xcode

Grab Xcode from the Apple website and install it. If you are on Xcode 4.4 or later, add the Command Line Tools by opening Xcode → Preferences and choosing the Downloads tab.

Get Xcode

Installing Git

Git can be installed through a package manager such as Homebrew, or by grabbing an installer straight from the Git website.

Get Homebrew Download Git

Installing NVM

Clone NVM into ~/.nvm, then source it from your shell profile:

git clone git://github.com/creationix/nvm.git ~/.nvm
source ~/.nvm/nvm.sh
echo "source ~/.nvm/nvm.sh" >> ~/.bashrc
nvm install v0.8.5
nvm alias default v0.8.5

On OS X, make ~/.bash_profile load ~/.bashrc by adding the following line to ~/.bash_profile:

[[ -s ~/.bashrc ]] && source ~/.bashrc

To activate a Node.js version you already installed, hand it to nvm use:

nvm use v0.8.4

View NVM on GitHub

Building a Basic HTTP Server

Spin up a minimal server with the built-in http module:

var http = require('http');

var server = http.createServer(function(request, response) {
  var url = request.url;
  response.writeHead(200, { 'Content-Type': 'text/html' });
  response.end("<h1>Hello from Node.js!</h1><p>You request the URL: " + url + "</p>");
});

server.listen(3000);

Comments

Brad Bicknell avatar
Brad Bicknell, 13 years ago: Thanks for the great screencast. Definitely looking forward to future casts.
leonardocsouza avatar
leonardocsouza, 13 years ago: Thank you for this awesome introduction! Also thank you so much for the detailed instructions in the Show Notes. Very helpful for those starting to play with Node.js. :)
Sumitro Chatterjee avatar
Sumitro Chatterjee, 13 years ago: Thanks a lot. This is great and just the method I prefer to learn a new language/tool.
rmyock avatar
rmyock, 12 years ago: Super helpful video and great way to learn the basics of node.js!
iamwave007 avatar
iamwave007, 11 years ago: love it

Tony Momoh, 10 years ago: splendid :D

RichardForrester, 10 years ago: Excellent!!! I'm really excited to learn about node.js -- coming from the Laravel framework.

Log in to add your comment!

Frequently Asked Questions

How do I install Node.js on Linux, Mac, and Windows?
The episode covers Node.js installation on all three platforms. On OS X you start by installing Xcode from the Apple website, then add the Command Line Tools via Xcode → Preferences, in the Downloads tab. Git comes from a package manager such as Homebrew or an installer from the Git website. Finally, NVM is cloned into ~/.nvm and sourced from your shell profile.
What is NVM and why would I use it?
NVM (Node Version Manager) lets you install and keep several Node.js versions side by side. The show notes show cloning NVM, sourcing nvm.sh, installing a chosen version like v0.8.5, and setting a default alias so the correct version loads in each new shell.
How do I switch between different Node.js versions?
After a version is installed with NVM, pass it to nvm use — for instance, nvm use v0.8.4 — to switch that version on for the current shell session.
How do I build a basic HTTP server with Node.js?
The episode closes with a minimal server built on the built-in http module. You call http.createServer with a request handler, write a 200 status plus a Content-Type header, end the response with HTML, and then call server.listen(3000) to begin accepting connections.
Which version of Node.js is used in this episode?
According to the show notes, this episode uses Node.js v0.8.5, with links to the matching downloads and API documentation.

Copyright © 2012 Brandon Tilley

Node.js is an official trademark of Joyent. This site is not formally related to or endorsed by the official Joyent Node.js open source or commercial project.

Nodecasts Home

Whether you are new to Node.js or coming from another stack, this episode gives you a repeatable setup you can reuse on any machine. Follow along with the show notes to install Node.js, keep versions organized with NVM, and confirm everything works by running your first HTTP server on port 3000.