JavaScript
JavaScript is a programming language designed in just 10 days in 1995 by Brendan Eich at Netscape Communications. Born as a scripting language for web browsers, it has grown over 30 years into one of the most widely used languages in the world — spanning front-end, server-side, desktop, and mobile. Its design roots lie in first-class functions from Scheme (a Lisp dialect) and prototype-based inheritance from Self, wrapped in a C-style curly-brace syntax.
Origin of the name
During development the language was called "Mocha" and then "LiveScript." It was renamed "JavaScript" at release in 1995 — not for technical reasons, but as a marketing decision to ride the popularity of Java, which was spreading rapidly at the time. The name was settled through a partnership between Netscape and Sun Microsystems (the creators of Java).
Java and JavaScript are entirely different languages. While the syntax shares some surface similarities — curly braces, similar variable syntax — the design philosophies, runtimes, and use cases are completely distinct. This naming decision has confused beginners for over 30 years. "Is JavaScript a simplified version of Java?" is a question that still comes up. The answer is "no."
The official name of the specification is ECMAScript. Because the name "JavaScript" is trademarked (by Oracle), the standards body Ecma International publishes the spec under the name "ECMAScript."
1995: The birth of JavaScript
In the early 1990s, the web was a static collection of HTML and CSS documents. Clicking changed nothing; submitting a form reloaded the entire page. Netscape Communications planned to embed a scripting language in its Navigator browser to bring pages to life, and assigned Brendan Eich to build it.
The constraints Eich worked under were severe.
- Build a working prototype in 10 days
- Make the syntax look like Java (a marketing requirement)
- Make it simple enough for non-programmers
Within those constraints, Eich chose to borrow first-class functions from Scheme (a Lisp dialect) and prototype-based inheritance from Self, then wrap them in C-style syntax. In May 1995, JavaScript shipped in a beta of Netscape Navigator 2.0.
Designing a language in 10 days left its marks. Many behaviors later recognized as bugs or inconsistencies — the complex rules of type coercion, typeof null === 'object', the non-intuitive behavior of comparison operators — are traces of that rushed design.
Brendan Eich's design philosophy
The heart of Eich's design is "treat functions as first-class citizens." Functions can be assigned to variables, passed as arguments, and returned as values — a design inherited from Scheme. This is the foundation that enables callbacks, event handlers, functional array methods (forEach, map, filter), and every modern asynchronous pattern in JavaScript.
Prototype-based inheritance comes from Self. Unlike Java and C++, which use classes as blueprints, JavaScript uses a model where new objects are created by cloning and extending existing objects as prototypes. The class syntax added in ES6 (2015) is syntactic sugar over this prototype mechanism.
Eich also held a philosophy of "keeping the JavaScript core small." Rather than packing features into the language itself, the design allows expansion through APIs and libraries. DOM manipulation, timers, and network requests are provided by browser APIs rather than by JavaScript itself — the same separation exists in Node.js, where those capabilities come from the runtime's APIs.
JavaScript's lineage
JavaScript inherits ideas from several languages and has influenced newer ones, including TypeScript and Dart.
| Language / Environment | Position | Relationship to JavaScript |
|---|---|---|
| ECMAScript | The international standard specification for JavaScript (managed by TC39 at Ecma International) | The official name of JavaScript |
| Node.js | Server-side JavaScript runtime published by Ryan Dahl in 2009 | Runs the V8 engine outside the browser |
| TypeScript | JavaScript superset with static types, published by Microsoft in 2012 | Compiles down to JavaScript |
| Deno | Next-generation runtime by Ryan Dahl, addressing lessons learned from Node.js | Natively supports TypeScript |
| Bun | JavaScript runtime / bundler / package manager aimed at fast startup | Uses the JavaScriptCore (Safari) engine |
| CoffeeScript | 2009 language for writing JavaScript with a Python-like syntax (shrank after ES6) | Compiles down to JavaScript |
| Dart | Developed by Google as an alternative to JavaScript. Still active as Flutter's language | Designed with JavaScript's influence in mind |
Key historical milestones
1997: ECMAScript standardization
Netscape submitted JavaScript to Ecma International in 1996, and ECMAScript 1 (ECMA-262) was published as an international standard in 1997. Microsoft's independent implementation, JScript, for Internet Explorer was a key motivation for pushing standardization quickly.
1999: ES3
Regular expressions and try/catch exception handling were added. ES3 became the most widely implemented version of ECMAScript for many years, serving as the de facto baseline until ES5 arrived in 2009.
2004–2005: The Ajax revolution
The launches of Gmail and Google Maps fundamentally changed how JavaScript was perceived. The concept of partial page updates without a full reload (Ajax, using XMLHttpRequest) demolished the notion that "JavaScript is a toy language" and opened the door to serious web application development.
2006: jQuery
John Resig published jQuery, a cross-browser library that smoothed over behavioral differences between browsers and exploded in popularity. Its CSS-selector-based element selection pattern ($(".class")) was later adopted by browsers as the standard querySelector API.
2009: ES5 and Node.js
ES5 brought Strict Mode, JSON support, and array methods (forEach, map, filter). That same year Ryan Dahl published Node.js, a runtime that brought JavaScript to the server side. The position of "one language for both front-end and back-end" was established here.
2015: ES6 (ES2015) — the biggest turning point
The first major update in six years introduced, all at once, the building blocks of modern JavaScript.
| Feature | What it provides |
|---|---|
let / const | Block-scoped variable declarations. Resolves scope issues with var |
| Arrow functions | () => {} syntax. Also changes how this is bound |
| Promise | A standard way to handle async operations, resolving callback hell |
| class syntax | Syntactic sugar over prototype-based OOP |
| Modules | Standard module system via import / export |
| Template literals | Backtick strings with embedded expressions |
From 2016 onward, ECMAScript moved to a "living standard" model with annual releases. TC39 reviews proposals through a four-stage process (Stage 0–4) before adoption.
2017: async/await
Introduced in ES2017, async/await is syntactic sugar over Promises that lets async code read like synchronous code. It became the dominant style for async JavaScript.
2012–: TypeScript
Microsoft published TypeScript, a superset of JavaScript with a static type system that compiles down to JavaScript. It was led by Anders Hejlsberg (the designer of Turbo Pascal, Delphi, and C#).
Comparison with contemporary languages
1995, the year JavaScript was born, was the dawn of the web. Here is how its design compares to languages that existed or emerged at the same time.
| Language | Appeared | Design direction | Relationship to JavaScript |
|---|---|---|---|
| Java | 1995 | Static typing, JVM, enterprise | Name borrowed only; no technical relationship |
| Perl | 1987 | Text processing, CGI scripting | Dominated server-side web in the 1990s |
| Python | 1991 | Readability, general-purpose | Competed with Perl on the server side via CGI |
| PHP | 1994 | HTML-embedding, web-focused | Complementary to JS: server-side to JS's client-side |
| VBScript | 1996 | Microsoft's IE scripting language | Competed with JS inside IE. Now essentially extinct |
The biggest difference between JavaScript and all of these is that JavaScript held the position of "the only language that runs inside the browser." Other languages competed on the server, but on the client side (inside the browser), JavaScript had a de facto monopoly — the foundation of its dominance today.
Modern usage
As of 2026, JavaScript is used across a wide range of domains that go far beyond the browser.
| Domain | Key technologies | Examples |
|---|---|---|
| Front-end UI | React, Vue.js, Angular, Svelte | Web application user interfaces |
| Server-side | Node.js, Deno, Bun | API servers, SSR (Server-Side Rendering) |
| Desktop apps | Electron | VS Code, Slack, Discord, Figma |
| Mobile apps | React Native, Expo | Cross-platform smartphone apps |
| Edge computing | Cloudflare Workers, Vercel Edge | Request handling at CDN edge nodes |
| Static sites | Next.js, Astro, Nuxt | SSG (Static Site Generation) + ISR |
The npm registry holds over 2 million packages, making it the largest software package ecosystem in the world. JavaScript's ability to cover both front-end and server-side work in a single language has made it widely adopted by startups and full-stack developers alike.
Common misconceptions
"JavaScript is a simplified version of Java"
Only the name is similar. The design philosophy, runtime, and language characteristics are entirely different. Java is a statically typed, class-based, object-oriented language that runs on the JVM; JavaScript is a dynamically typed, prototype-based language that runs in browsers and Node.js. The naming was a marketing decision.
"JavaScript is a carelessly designed, broken language"
The 10-day design sprint left a lasting impression that the whole language is flawed. But the core — first-class functions, prototype inheritance, closures — was deliberately inherited from theoretically sophisticated languages, Scheme and Self. Known issues like typeof null === 'object' are documented in the ECMAScript specification and intentionally left in place for backward compatibility.
"Once you use TypeScript, you don't need to understand JavaScript"
TypeScript is a superset of JavaScript; it compiles to JavaScript. The runtime is JavaScript itself, and using TypeScript does not eliminate the need to understand JavaScript. Learning TypeScript without a solid JavaScript foundation leads to confusion about the causes of type errors and runtime behaviors.
"jQuery is no longer needed"
Modern front-end projects increasingly avoid jQuery. At the same time, a large portion of the world's websites — including those running WordPress — still run on jQuery-dependent codebases. The ability to read and maintain jQuery code continues to have practical value in industry.
"Single-threaded means slow"
JavaScript is single-threaded, but it achieves sufficient performance for I/O-heavy web applications through the event loop, asynchronous I/O, and Web Workers (for multi-threaded computation). V8's JIT compilation also improves compute performance year over year.
Related terms
- Brendan Eich — The creator of JavaScript. Built the prototype at Netscape in 10 days in 1995. Later involved in founding Mozilla, the organization behind Firefox
- ECMAScript (ECMA-262) — The international standard specification of JavaScript, managed by TC39 at Ecma International. Referenced by version names like "ES5," "ES6," and "ES2015"
- TC39 — The technical committee responsible for the ECMAScript specification. Evaluates new features through a four-stage process (Stage 0–4)
- V8 — Google's JavaScript engine, used in Chrome and Node.js. Delivers high performance via JIT compilation
- Node.js — Server-side JavaScript runtime published by Ryan Dahl in 2009, built on the V8 engine
- Ajax (Asynchronous JavaScript and XML) — A technique for exchanging data with a server without reloading the whole page. Spread widely with the launches of Gmail and Google Maps in 2004–2005
- jQuery — JavaScript library published by John Resig in 2006. Widely adopted for cross-browser compatibility and simplified DOM manipulation
- TypeScript — JavaScript superset with a static type system published by Microsoft in 2012. Compiles down to JavaScript
- npm (Node Package Manager) — JavaScript's package registry and package manager. Hosts over 2 million packages, the largest software registry in the world
- Prototype chain — JavaScript's object inheritance mechanism. Each object holds a reference to its prototype, and property lookups traverse the chain until the property is found
- JScript — Microsoft's proprietary JavaScript-compatible implementation for Internet Explorer. A product of the browser wars that accelerated the push for standardization