w1coding.comAll tutorials

Node.js Environment Setup

Node.js lessons
  1. Environment Setup
  2. Introduction To Node.js
  3. Installing Node.js
  4. Your First Node.js App
  5. Node.js Modules
  6. npm Node Package Manager
  7. Node.js File System Module
  8. Creating A Web Server
  9. Routing In Node.js
  10. Event Loop And Events
  11. Node.js Streams
  12. Buffers In Node.js
  13. Node.js And Express.js
  14. Handling Get And Post Requests
  15. Using Middleware In Express
  16. Templating Engines
  17. Connecting To MongoDB
  18. CRUD Operations With MongoDB
  19. Mongoose Basics
  20. REST API With Express
  21. User Authentication
  22. Using JWT In Node.js
  23. File Uploads With Multer
  24. Deploying Node.js Apps
  25. Debugging Node.js Apps
  26. Environment Variables
  27. Using Nodemailer
  28. Scheduling With Node Cron
  29. Real Time Apps With Socket.io
  30. Unit Testing In Node.js
  31. Best Practices And Conclusion

Node.js runs JavaScript outside the browser. Install a supported LTS release and use npm to manage dependencies inside each project.

What you need

  • Node.js LTS from nodejs.org
  • A code editor
  • A terminal

Set up your environment

  1. Install Node.js using an official download method appropriate for your operating system. Reopen the terminal.
  2. Run node --version and npm --version. Create a folder named node-practice.
  3. In that folder run npm init -y to create package.json, then save the example as app.js.
  4. Run the file in the terminal. This console example does not require a web server or an npm package.

Your first check

Save as app.js

const greeting = 'Hello from w1coding.com';
console.log(greeting);

Run or verify

node app.js

Expected result: The terminal prints Hello from w1coding.com.

Common setup problems

  • If node is not recognised, reopen the terminal after installation and check PATH.
  • Browser APIs such as document are not available in a basic Node.js console program. Keep project dependencies local rather than installing everything globally.

Official documentation

Guide reviewed 17 November 2026. Check the linked vendor documentation for current supported versions and operating systems.