Open http://nodejs.org/, then click on Download (http://nodejs.org/download/),
so you can view the following details on the screen.

Now, based on your Windows 7 system type (meaning whether it is 32-bit or 64-bit), download the appropriate Windows Installer. If you don't know how to determine if you are using 32-bit or 64-bit Windows, please Click Here.
Open Command Prompt with administrator privileges; see the following image for more information. Right-click on Command Prompt and select 'Run as administrator'.
Now run the following command.
msiexec /i node-v0.10.26-x64.msi








Type the following command and press Enter.
npm ls -g


You're now done.
Using a web server
I copied the following code from the nodejs.org site and saved it as example.js.
var http = require('http');<br>
http.createServer(function (req, res) {<br>
res.writeHead(200, {'Content-Type': 'text/plain'});<br>
res.end('Hello World\n');<br>
}).listen(1337, '127.0.0.1');<br>
console.log('Server running at <a
href="https://web.archive.org/web/20221024040305/http://127.0.0.1:1337/'">http://127.0.0.1:1337/'</a>);
Now run this program from the command line,


TCP server
Posted on April 29, 2014 by Amit Pandya in nodejs