From HandWiki
Short description: Specification for Javascript and other programming languages
ParadigmMulti-paradigm: prototype-based, functional, imperative
Designed byBrendan Eich, Ecma International
First appeared1997; 26 years ago (1997)
Typing disciplineweak, dynamic
Major implementations
JavaScript, ActionScript, JScript, QtScript, InScript, Google Apps Script
Influenced by
Self, HyperTalk, AWK, C, CoffeeScript, Perl, Python, Java, Scheme
ECMAScript (file format)
Crystal source.svg
Internet media typeapplication/ecmascript
Developed bySun Microsystems,
Ecma International
Initial releaseJune 1997; 26 years ago (1997-06)
Latest release
Edition 13
(June 2022; 1 year ago (2022-06))
Type of formatScripting language
WebsiteECMA-262, ECMA-290,
ECMA-327, ECMA-357,

ECMAScript (/ˈɛkməskrɪpt/; ES)[1] is a JavaScript standard intended to ensure the interoperability of web pages across different web browsers.[2] It is standardized by Ecma International in the document ECMA-262.

ECMAScript is commonly used for client-side scripting on the World Wide Web, and it is increasingly being used to write server-side applications and services using Node.js and other runtime environments.[citation needed]

ECMAScript, ECMA-262, JavaScript

ECMA-262, or the ECMAScript Language Specification, defines the ECMAScript Language, or just ECMAScript.[3] ECMA-262 specifies only language syntax and the semantics of the core application programming interface (API), such as Array, Function, and globalThis, while valid implementations of JavaScript add their own functionality such as input/output and file system handling.


The ECMAScript specification is a standardized specification of a scripting language developed by Brendan Eich of Netscape; initially named Mocha, then LiveScript, and finally JavaScript.[4] In December 1995, Sun Microsystems and Netscape announced JavaScript in a press release.[5] In November 1996, Netscape announced a meeting of the Ecma International standards organization to advance the standardization of JavaScript.[6] The first edition of ECMA-262 was adopted by the Ecma General Assembly in June 1997. Several editions of the language standard have been published since then. The name "ECMAScript" was a compromise between the organizations involved in standardizing the language, especially Netscape and Microsoft, whose disputes dominated the early standards sessions. Eich commented that "ECMAScript was always an unwanted trade name that sounds like a skin disease."[7] ECMAScript has been formalized through operational semantics by work at Stanford University and the Department of Computing, Imperial College London for security analysis and standardization.[8] "ECMA" stood for "European Computer Manufacturers Association" until 1994.

Version history

Main page: ECMAScript version history


Main pages: ECMAScript syntax and JavaScript#Features

The ECMAScript language includes structured, dynamic, functional, and prototype-based features.[9]

Imperative and structured

ECMAScript JavaScript supports C style structured programming. Previously, JavaScript only supported function scoping using the keyword var, but ECMAScript 2015 added the keywords let and const allowing JavaScript to support both block scoping and function scoping. JavaScript supports automatic semicolon insertion, meaning that semicolons that are normally used to terminate a statement in C may be omitted in JavaScript.[10]

Like C-style languages, control flow is done with the while, for, do / while, if / else, and switch statements. Functions are weakly typed and may accept and return any type. Arguments not provided default to undefined.

Weakly typed

ECMAScript is weakly typed. This means that certain types are assigned implicitly based on the operation being performed. However, there are several quirks in JavaScript's implementation of the conversion of a variable from one type to another. These quirks have been the subject of a talk entitled Wat.[11][12]


ECMAScript is dynamically typed. Thus, a type is associated with a value rather than an expression. ECMAScript supports various ways to test the type of objects, including duck typing.[13]


Since ES 2015, transpiling JavaScript has become very common. Transpilation is a source-to-source compilation in which newer versions of JavaScript are used, and a transpiler rewrites the source code so that it is supported by older browsers. Usually, transpilers transpile down to ES3 to maintain compatibility with all versions of browsers. The settings to transpiling to a specific version can be configured according to need. Transpiling adds an extra step to the build process and is sometimes done to avoid needing polyfills. Polyfills create new features for older environments that lack them. Polyfills do this at runtime in the interpreter, such as the user's browser or on the server. Instead, transpiling rewrites the ECMA code itself during the build phase of development before it reaches the interpreter.


In 2010, Ecma International started developing a standards test for Ecma 262 ECMAScript.[14] Test262 is an ECMAScript conformance test suite that can be used to check how closely a JavaScript implementation follows the ECMAScript Specification. The test suite contains thousands of individual tests, each of which tests some specific requirement(s) of the ECMAScript specification. The development of Test262 is a project of the Ecma Technical Committee 39 (TC39). The testing framework and individual tests are created by member organizations of TC39 and contributed to Ecma for use in Test262.

Important contributions were made by Google (Sputnik testsuite) and Microsoft who both contributed thousands of tests. The Test262 testsuite consisted of 38014 tests (As of January 2020).[15] ECMAScript specifications through ES7 are well-supported in major web browsers. The table below shows the conformance rate for current versions of software with respect to the most recent editions of ECMAScript.

Scripting engine conformance
Scripting engine Reference application(s) Conformance[16]
ES5[17] ES6 (2015)[18] ES7 (2016)[19] Newer (2017+)[19][20]
SpiderMonkey Firefox 94 100% 98% 100% 100%
V8 Google Chrome 95, Microsoft Edge 95, Opera 80 100% 98% 100% 100%
JavaScriptCore Safari 15 100% 99% 100% 90%

See also


  1. Stefanov, Stoyan (2010). JavaScript Patterns. O'Reilly Media, Inc.. p. 5. ISBN 9781449396947. Retrieved 2016-01-12. "The core JavaScript programming language [...] is based on the ECMAScript standard, or ES for short." 
  2. Wirfs-Brock, Allen; Eich, Brendan (2020-05-02). "JavaScript: The First 20 Years". Proceedings of the ACM on Programming Languages 4: 1–189. doi:10.1145/3386327. 
  3. Guo, Shu-yu (2022-02-14). "ECMAScriptÂŽ 2022 Language Specification". Retrieved 2022-02-14. 
  4. Krill, Paul (2008-06-23). "JavaScript creator ponders past, future". InfoWorld. 
  5. "Netscape and Sun announce JavaScript, the Open, Cross-platform Object Scripting Language for Enterprise Networks and the Internet". Netscape. 1995-12-04. 
  6. Press Release (November 15, 1996). "Industry Leaders to Advance Standardization of Netscape's JavaScript at Standards Body Meeting". Netscape. 
  7. Eich, Brendan (2006-10-03). "Will there be a suggested file suffix for es4?". 
  8. Maffeis, Sergio; Mitchell, John C.; Taly, Ankur (2020-01-03). "An Operational Semantics for JavaScript". Association for Computing Machinery. 
  9. "About". ECMAScript. 
  10. David Flanagan (17 August 2006). JavaScript: The Definitive Guide: The Definitive Guide. "O'Reilly Media, Inc.". p. 16. ISBN 978-0-596-55447-7. Retrieved 11 November 2019. 
  11. Bernhardt, Gary. "Wat". CodeMash 2012. Retrieved 2021-08-18. 
  12. Gilbertson, Scott (26 January 2012). "Jokes for Nerds: Wat Moments in Programming". Wired. Retrieved 22 August 2021. 
  13. "JavaScript data types and data structures – JavaScript | MDN". 2017-02-16. 
  14. "ECMAScript Language – test262". 
  15. "tc39/test262". January 24, 2020. 
  16. ES5 is the baseline for this test suite. The conformance rate for other editions reflects support for new features only, not a comprehensive score.
  17. "ECMAScript 5 compatibility table" (in en). 
  18. "ECMAScript 6 compatibility table" (in en). 
  19. 19.0 19.1 "ECMAScript 2016+ compatibility table" (in en). 
  20. Composite score that includes new features from ES7 through next edition drafts