TOC
Getting started:

The tools you need

JavaScript is one of the simplest programming languages to get started with when it comes to the tools you need. In fact, you probably won't have to download anything to get started: JavaScript can be written in any text editor, even a simple one as Windows Notepad (or the equivalent Mac/Linux alternative) and when it comes to interpreting and testing the code, all you need is a webbrowser. In other words, you can get started learning JavaScript without having to pay for an expensive IDE or downloading a complicated compiler/interpreter.

With that said, there are still some tools you can get to enhance the experience. Let's talk a bit about what you can do.

The editor

As I said, Notepad or any other simple text editor will do when you write JavaScript, but if you have EVER used an editor actually intended for writing code, you know that it can improve your efficiency a LOT! Modern code editors/IDE's (Integrated Development Environment) will help you write code faster and more efficient with features like AutoComplete and IntelliSense. This is also true for JavaScript.

Since JavaScript is so closely tied to the web, you may already be using a code/web-editor for writing HTML and/or CSS. If so, it likely supports JavaScript as well and I would suggest that you simply stick with this editor when learning JavaScript. If not, I suggest that you get your self a code editor/IDE.

Let's discuss the various options:

An online editor

To get started, you may want to use an online editor. Since JavaScript has such close ties to the web, there are loads of online editors which can do a lot of the same things as a "real" editor, and it can be used directly from your browser, without having to install anything. They are often referred to as "playgrounds" or "fiddles", because they are mostly designed to test, demonstrate and share code, and not so much for working on large projects (although some of them can even be used for this), which makes them perfect for testing and playing with the code examples of this tutorial.

So, if you don't already have a preferred web editor, and you're just looking to see if JavaScript is something you want to spend some time learning, I can definitely recommend an online editor. They offer various levels of IntelliSense, helping you to write JavaScript code more efficiently, and the code can be tested instantly, directly in the browser. Here are a couple of suggestions:

Try them out and see which one you like the most.

A simple text editor

As already mentioned, you can just use any kind of simple text editor, like the one that is probably included with your operating system (Notepad for Windows etc.). However, this is mostly for the purists out there, who insists on getting as little help as possible. For everyone else, I recommend one of the other alternatives listed in this article, where you get a helping hand from features like IntelliSense, syntax check and so on.

A web editor

There are several good web editors out there, with a strong focus on web related technologies like HTML, CSS and JavaScript. They are sometimes referred to as "HTML editors", probably because that's how they started, but most of them will support JavaScript as well. I'm not going to recommend a specific editor here, but Wikipedia has a list of editors that you can check out.

Visual Studio Code

Developed by Microsoft, Visual Studio Code is one of the most comprehensive IDE's for writing code in MANY languages, including JavaScript. Since this is a very powerful, multi-purpose tool, it may not be the best choice if you're just getting started. But if you want a complete solution for HTML, CSS, JavaScript and basically any other language, VS Code is definitely worth giving a try. It's available for Windows, Mac and Linux and can be downloaded here.

The interpreter/JavaScript engine

Unless you have specific requirements, I suggest that you use the JavaScript engine already available to you: The one in your webbrowser. So, whether you write your code locally in a simple text editor and open it in the browser, use an IDE and have it launch the webbrowser for you, or write the code in one of the online editors and test it directly from there, you are good to go.

On the other hand, if you already know that you will want to use JavaScript outside of the browser, e.g. through Node.js, you should go and download that. It's not within the scope of this tutorial though - we only discuss the language.

Summary

JavaScript is nice and easy to get started with - all you need is a simple text editor, like Notepad for Windows or any built-in alternative for Linux or Mac, and a webbrowser. With that in place, let's continue our journey of learning JavaScript.


This article has been fully translated into the following languages: Is your preferred language not on the list? Click here to help us translate this article into your language!