A Node.js application consists of the following three important components. Components are:
1. Import required modules – the require directive to load Node.js modules.
2. Create server − A server which will listen to client's requests similar to Apache HTTP Server.
3. Read request and return response − Created server will read the HTTP request made by the client who can be a browser or a console and return the response.