The simplest explanation: JavaScript is a programming language that runs in the browser. When JavaScript was officially made, it could only run in browser(more of a frontend language). It couldn’t run on sever side like other languages (Python, PHP etc). So Node.js was created from JavaScript to allow JavaScript to run on the server side (thus the backend). Yes, if you have a good grip on JavaScript, learning other frameworks like React and TypeScript will be easier Answer from drauphnir on reddit.com
🌐
Reddit
reddit.com › r/learnjavascript › what is the difference between javascript and node.js?
r/learnjavascript on Reddit: What is the difference between Javascript and Node.js?
June 21, 2025 -

Hi everyone, I'm a beginner in JavaScript.
I've just finished learning HTML and CSS.
I see some people talking about JavaScript, while others mention Node.js.
I've also heard of Next.js, Ruby, React.js, and more.
I don't really understand the differences between them.
Is it true that if I have a good grip on JavaScript, the rest will be easier to pick up since they only have minor differences?
I welcome all kinds of answers and advice in my JavaScript learning journey.
Thanks in advance!

🌐
Reddit
reddit.com › r/learnprogramming › difference between javascript and node.js
r/learnprogramming on Reddit: Difference between Javascript and Node.js
June 19, 2022 -

So I am quite confused about this. I have seen a lot of people recommending to learn Javascript and then Node.js. I was not sure what Node.js is and after some research I have learned that it is a Runtime Environment to run Javascript outside of the browser.

So why do people say to "learn" node.js? Aren't you automatically able to "use" it once you can code Javascript?

As far as I can see the only difference is where you run your code...

Seems very confusing.

Top answer
1 of 5
406
So when most people start learning Javascript, it refers to Javascript in the browser. Things like button events, building drop downs. And then maybe libraries like react. A front end on its own is not too useful. You usually want to make some api calls that will communicate with a backend app and eventually fetch or save some data from a database. When people say "learn node" they mean "learn how to build a backend application with Javascript" this includes learning how to read and write data from a database and then create Api endpoints that your frontend Javascript will call. Usually using a library like express to do this.
2 of 5
315
JavaScript is a programming language designed for scripts in the browser. A JS script is a text file (just like html and css) that the browser receives and executes. This is done by a part of the browser called the JavaScript engine. When in 2008 Google released Chrome, it gained popularity very rapidly. One of the many reasons for that popularity is it's very fast JavaScript engine. Chrome's underlying code (including it's JS engine) is open source. So a developer named Ryan Dahl basically copied the JS engine code and put it into a standalone program which he called NodeJS. NodeJS is in essence the JS engine from chrome but without all the browser stuff: no document (webpage), no user interface, etc. It just runs the code in a JS file. What is node used for? Anything really that you can program. Desktop applications (for example discord, VsCode are programmed with JS), mobile apps (Progressive web apps, react native, etc), but most importantly servers. You can write your own server code that connects your frontend (browser JS) to for example a database. This can be a massive benefit for developers as it does not force you to use different languages for the frontend (which needs JS) and backend (PHP, C#, Python, Java, etc). You can now use JS for everything which makes it easier for a developer to work on the full stack (frontend, backend, database, etc).
🌐
Reddit
reddit.com › r/askprogramming › what is the difference between node js and javascript.
r/AskProgramming on Reddit: What is the difference between node js and javascript.
March 10, 2018 -

As I understand it, you can write javascript in a text editor like sublime or atom but to use node you need to actually download it from the internet. What are you downloading and what is it allowing you to do that you can not do with vanilla js?

🌐
Reddit
reddit.com › r/learnjavascript › what exactly is the difference between js and node.js ??
r/learnjavascript on Reddit: What exactly is the difference between JS and node.js ??
September 28, 2021 - js is usually run from within a web browser client side, and is heavily restricted in system interaction for security reasons · nodejs is there to wait for a url path to light up and then it serves out files · the files picked up client side ...
🌐
Reddit
reddit.com › r/node › node.js or java for backend? seeking advice for fullstack transition!
r/node on Reddit: Node.js or Java for Backend? Seeking Advice for Fullstack Transition!
August 30, 2024 -

Hey everyone,

I could really use some advice. I've been working as a frontend developer for almost 2 years now, mainly with React, React Native, and Redux. I want to level up and become a fullstack developer, so I'm diving into backend development.

Initially, I thought of learning Node.js since it uses JavaScript, which I’m already comfortable with. But one of my seniors suggested I should consider Java because it’s more powerful and could lead to better job opportunities.

Here's where I’m stuck:

  1. Familiarity: I know JavaScript pretty well, so picking up Node.js might be easier and faster for me.

  2. Learning Curve: I’m a bit of a slow learner, and Java would be completely new territory, meaning I’d have to start from scratch.

  3. Career Prospects: While Node.js seems like the easier path, Java supposedly offers more robust capabilities and better job prospects.

For those of you who have experience with both or have made the transition from frontend to fullstack, what would you advise? Should I go with Node.js for a smoother learning experience, or should I tackle Java for potentially better career opportunities?

Thanks a ton for your help!

Top answer
1 of 5
53
It’s more about the concepts. Are you familiar with (or do you want to learn) how Spring works? Learning Java is not hard. It’s dot notation, like JS, but it’s compiled, there’s strict typing, and much more heavily focused around OOP. How well do you know OOP? How familiar are you with abstraction? If I were you, I’d stick with something like Nest.JS and focus on learning proper typescript, and then move into Java. If you’re not good with key programming principles, then Java will be brutally hard. If you’re familiar with stuff like OOP, inheritance, polymorphism, abstraction, singletons, factory methods, et al., then Java might be a good challenge! Also, consider time. Do you have the time to learn Java? Or would that time be better spent on learning a solid TS framework, like Nest.JS? I’d say learn TypeScript properly, and focus on Nest.JS (or some other framework), and then learn Java and port your api to it when you have the time! Good luck either way, bud! [EDIT] career wise, don’t worry. PLENTY of node jobs out there! But be sure to stand out by knowing programming principles, not just node. I’m a hiring manager. I literally don’t give a fuck if you know how to make an express app. I care that you know how to stream a file, what buffers are, how to find performance issues, database normalization, et al. If you know that, learning a new language becomes a lot easier!
2 of 5
38
You'll pick the concepts faster in the language you alresdy know. Afterwards, you can choose to transition to Java. More Java jobs but at the end of the day, if you know and understand the concepts very well, it doesn't matter what you choose
🌐
Reddit
reddit.com › r/frontend › should i learn node js or react ?
r/Frontend on Reddit: Should i learn node js or react ?
January 4, 2023 - I’d suggest learning both when you have a grasp of vanilla JS. ... Both, but start with nodeJS. It's essential to understand APIs and get skills into building them, as well as communicating with databases. React is not too complicated once you master javascript.
Find elsewhere
🌐
Reddit
reddit.com › r/webdev › really confused about nodejs and why it’s important and how it works.
r/webdev on Reddit: Really confused about nodeJS and why it’s important and how it works.
August 1, 2022 -

So I am having a hard time actually understanding the importance of nodeJS and how it actually works.

From my research here’s what I have found and understood.

Basically, when you type in a website name, The server sends the HTML, CSS, and JavaScript code to your browser. To understand the example better let’s just say the browser is Google Chrome. Google Chrome uses V8 as the runtime environment. V8 essentially converts the code into machine code so that the machine aka my laptop in this case can interpret it and display it. This is what we called client-side.

nodeJS is server-side essentially. Meaning, when I want to access things on the back end. I send the code to the server. It converts code into machine code which it interprets and sends back machine code again, which nodeJS converts to JavaScript?

The reason it’s important it because nodeJS uses V8’s efficient methods of turning JavaScript to machine code and machine code to JavaScript, but without having a browser do it.

However, my confusion is, would this mean, actually servers would have to have nodeJS installed on the server to receive Javascript, turn it into machine code which the server can interpret and send back machine code to my laptop, which nodeJS will change to JS. Isn’t this how Java or PHP works. They have an interpreter on the server to change it from Java/PHP to machine code?

Can someone provide a step example, like I did above for client and server side using nodeJS so I can understand this correctly please. I am confusing myself.

Top answer
1 of 5
86
You don't "send code to the server". Node is running javascript server side, but it is server side code, and has no particular relationship to the javascript running in the browser. (Note that accepting arbitrary code from a browser and running it would be a huge security hole in any case.)
2 of 5
74
In order to fully understand this, we must first understand a few things The client-server architecture, i.e what's a client and what's a server? What's JavaScript and why do we need it? What's V8 Engine? Client Server Architecture Server You can think of it as a shopkeeper or a receptionist They take in requests/orders and process those requests in some way (If required) and gives back the response. E.g If you asked a Bakery Shopkeeper for a Cake, they will first take in your order (your request), prepare your cake (process your request) and then give you that cake (Response) Client The Browser is the client. The one who places the order, The one who is going to consume the cake. The one who "makes the request" APIs The Client and the Server Both are running some kind of software, i.e for making requests and responses respectively, but we need some way for these two software to communicate with each other, that's where APIs come into play. The client and server are not passing around code, but rather exchanging messages, and there are many formats in which these messages are sent, e.g HTTP, Websockets, Raw TCP/UDP etc. The code (on both ends, client and server), whether they are written in Javascript or any other Language, they're just there to handle these messages. That's why the client and server can be agnostic to each other as long as they follow the correct format of the messages. Which means, the client would not care whether the server is written in Javascript or Rust or Malbolge, and conversely, the server wouldn't care whether the client is written in JS or Kotlin or Swift or Befunge. They only care about the format of the message, and both the client and the server need to follow that "Contract" between them What is JavaScript It is a Programming Language, just like Java or PHP (Just different in terms of how it is executed). It requires a Runtime Environment which executes JS code. It does many things like: On the Browser Makes a webpage interactive Handles logic on the Client's browser (Sometimes) makes requests to the server for resources On The Server Responds to client's request Handles files on the server Handles Communication with a Database V8 As mentioned above, JavaScript requires a Runtime Environment, and V8 is one of the most popular runtime environments for JS. A Runtime environment basically takes in JS code and essentially converts that to Assembly while also adding some optimisations to the code. That assembly is then gets fed into the CPU which converts it to machine code and executes it. The V8 Runtime Environment also "keeps track of" and "cleans up" memory in a program Node JS Since the birth of JS in 1995, It was only capable of running inside a browser, but in 2009-10 Ryan Dahl basically put the V8 Runtime environment in a program that was capable of running Server Side Logic i.e responding to client requests, handling the file system, communicating with databases etc. Which allowed developers to write that server side Logic using Javascript When I go to a website, How does my browser know what JS code to run When visiting a website, the browser (Client) will make a request to the server The server then responds with a JS file. The file itself is a response of that request and the Browser recognises it as a JS source file i.e it knows that it needs to run this file. The Browser then gives the file to the Runtime Environment, which does the execution of that code on the client side
🌐
Reddit
reddit.com › r/learnprogramming › should i go with node.js or php
Should I go with Node.js or PHP : r/learnprogramming
October 17, 2023 - Because you know JavaScript, go ahead with Node.js you’ll be more confident while learning it.
🌐
Reddit
reddit.com › r/node › should i choose nodejs?
r/node on Reddit: Should i choose nodejs?
August 12, 2024 -

Should i choose nodejs?

I recently started learning MERN. I can create crud websites. As a newbie i am confused with choosing a backend. Heard most companies prefer dotnet or Java springboot . These are my concerns:

  1. Is this a fact or a rumour?

  2. Why is nodejs that not much popular popular?

  3. Will the scenario ever change in future?

Give me facts and figures to support your claim

Incase you support nodejs, provide some good resources.📚

🌐
Reddit
reddit.com › r/node › why nodejs is so popular and why you choose it?
r/node on Reddit: Why NodeJS is so popular and why you choose it?
March 8, 2022 -

Hi, so I was wondering why a lot of people use node as a backend runtime?

I've started with PHP , and I've seen that php is declining in popularity and some say it's harder to scale your web app using php or it's unsafe language to write in.

Then I searched for PHP alternatives I stumbled on a JavaScript run time called "NodeJS", at first I've liked how's it's non-blocking and it's JavaScript but on the server, but after playing around a bit with it, I didn't understand why people use it for production, I'm not a fan of downloading other people code and run it or every time i need to learn a small syntax to use a package, and it's very hard for people who don't want to use frameworks or npm packages to learn the NodeJS core because of the horrible documentation, you can't search for a function, some of node functions isn't clear what they do and what arguments they take and the type of data a function or a method takes.

I just don't get why node is so popular, is it because people don't want to learn other backend languages, or the quick plug and play concept of npm packages?

Top answer
1 of 24
106
I'm not a fan of downloading other people code and run it Sorry, but you're in the wrong field of work then. PHP has Composer, Python has pip, Perl has CPAN, C# has NuGet, Rust has cargo, etc. The era of programming everything yourself is long over. It's simply not feasible, anymore. And extending the "standard functionality" isn't the solution. Even people programming in C++ with it's extensive stdlib complain that it's not enough and argue that without Boost , C++ is unusable. There will always be something that YOU think should be part of the core functionality. Node's tooling leaves everything else in the dust. The JavaScript/Node community is what popularized (not invented) things like HMR, asynchronous programming, E2E-Testing. Promises have become so popular that they're making their way into other languages. It's also easy to get into and performance-wise it can hold up against Java even, which is nuts. Imagine programming Java with its crappy digital ecosystem and bloated IDEs. Makes me shudder.
2 of 24
92
This is quite a common question from people coming from PHP, which has a far larger core API. Node philosophy is different - the Core API is much more lightweight and developers are encouraged to build out their API as they see fit. I prefer that philosophy to the kitchen-sink philosophy of PHP. It's true that the JS ecosystem is bloated. If you want to do something, there's probably a package that already does it (or something similar). Obviously the quality of those packages vary. Some are good, some are bad. Some packages might be good but are based on a differing philosophy than your project (which might make them a poor or awkward choice for the project). It's entirely up to you whether you want to write your own Mongo driver, or just npm i mongodb. If you want to write your own driver you better have a clear, demonstrable reason why your propsed solution is better than the existing one - not just an ideological mistrust of other's code. Generally someone is paying you to deliver a project, not a library. I also like that my frontend code and backend api can sit within the same language/stack. It reduces context switching and helps with resourcing.
🌐
Reddit
reddit.com › r/node › beginner question: difference between node and vscode?
r/node on Reddit: Beginner Question: difference between Node and VSCode?
September 13, 2022 -

Hey guys, I apologize if this is a simple question, I am just pretty uneducated regarding all this. I am trying to teach myself how to code and am using a coding book as well as the Odin Project. The Odin project suggests I download VScode which is a code editor while my book suggests I download node.js to try out Javascript code. Are they both not the same thing? I am mainly just looking for something to test my code on, but it seems like these two are different things and I'm a bit confused in regards to what each focuses on. Any explanation would be appreciated, thank you.

🌐
Reddit
reddit.com › r/programmerhumor › java vs node.js
r/ProgrammerHumor on Reddit: Java vs Node.js
July 5, 2018 - If your goal is to develop an app using the same language and workflow for both front-end and back-end, then JavaScript is the strongest contender, if only because of the front-end where JS is the go-to option (browsers understand it natively, ...
🌐
Reddit
reddit.com › r/reactjs › difference between react, react native, node.js, vanilla.js, angular.js and javascript
r/reactjs on Reddit: Difference between React, React native, Node.js, vanilla.js, angular.js and javascript
July 26, 2019 -

To give some context, I am a beginner to programming and keen on learning web development. Since the time I began to search for tutorials and languages to learn, I was bombarded with all these different languages. I know a fair bit of C, HTML, CSS, and javascript. During the same time I also came across people advising me to learn Python for web dev. All this has left me in a mind block and everytime i try to understand them Im left more confused. Which amongst 'React, React native, Node.js, vanilla.js, angular.js, javascript, python' should i learn and whats the basic difference ? This confusion has been a bit of a demotivator and I'm not able to focus on anything. Any help is appreciated. Thanks :)

Top answer
1 of 2
5
Javascript and Vanilla.js Javascript (JS) = the language React, React native, Node.js, angular.js are written in. 'vanilla.js' is like a slang term meaning ONLY JS, no plugins, libraries, frameworks etc. vanilla.js = JS ONLY. Node.js Node.js, is a server side language like PHP/Python. It handles requests, serves files, interacts with databases etc. It is written in JS and has some built in processes to make server side performance possible since JS started, and is primarily used, as a client side scripting library. In other words, JS was built to run in the browser, but some craft folks created Node.js to use JS on the server. The idea being that if I knew how to use JS in the browser, I can now do server side scripting with it as well. React and Angular React and Angular are amongst what are referred to as JS 'Frameworks'. They are a layer on top of JS (and written in JS) that allow you to do some processes easier. Each framework has a different specialization and is kind of like a tool to get the job done. Depending on your project specifications, one framework will be a better choice over the other. React Native Again this is another Framework that leverages the React framework and is spcifically for deploying mobile apps. I personally haven't dug much into it, but if you're starting out you shouldn't be anywhere near React Native (unless of course your first project is a mobile app, then it could potentially be an option). Where should you start? You know a 'fair bit of HTML, CSS and JS'. That's good, those are the 3 of the 4 pillars of web dev. So you're 75% of the way there to do web dev. You will need to learn a server side language like Python or Node.js in order to serve your beautiful CSS styled HTML templates to a user in a browser. Both are suitable options with their different benefits. And then before you start jumping into React, Angular, Vue etc. You need to ensure you are proficient in JS above everything else. Since most of the above are written in JS, if you struggle with JS you'll struggle with Node, React, Angular etc.
2 of 2
1
React: Facebook's web framework, quite good. React native: React for mobile apps. Node.js is Google's server side implementation of JavaScript, also very good, and surprisingly fast. Vanilla.js: no idea. I'll Google it later. Angular.js: Google's web framework, a bit old, being replaced by Flutter (also Google). JavaScript: the programming language used in all of the aforementioned. Which one should you learn, no idea. Well, JavaScript is fundamental. Learn node if you want to do server side JavaScript, for API's with graphql, REST etc. React if you want to do client side. I like the typed functional languages that compile to JavaScript, but still using react. I think if you want to do front end stuff, react is going to get you a job, so will angular, and to a lesser extent, vue.js. Apologies for the scatty post. I'm not an authority on any of this, it's just my perception.
🌐
Reddit
reddit.com › r › web_design › comments › 4xchg9 › eli5_difference_between_jquery_angularjs_nodejs
ELI5: Difference between JQuery, Angular.js, Node. ...
August 12, 2016 - I only know basic HTML and CSS but of course I am way far behind from the modern web standards and applications. Somebody please explain me where the world is heading to · Create your account and connect with a world of communities
🌐
Reddit
reddit.com › r/javascript › [askjs] what is the relationship between javascript, node.js,, next.js, and react.
r/javascript on Reddit: [AskJS] What is the relationship between Javascript, Node.js,, Next.js, and React.
June 4, 2024 -

Im trying to gain a deeper understanding of how JavasScript interacts with Node.js, Next.js, and React. What does Node.js, being a runtime for JavaScript, do on a lower level? What does Next.js do? How are they incorporated when using React?