Lua
Lightweight, embeddable scripting language with a simple C API.
Wikipedia / Wikimedia Commons
Lua is a lightweight, high-level, multi-paradigm programming language built for embedding into other applications. Because its interpreter is written in ANSI C, it runs on many platforms. The language was created in 1993 to let users customize software, at a time when demand for such flexibility was growing. It includes basic procedural programming features but leaves out complex or domain-specific ones, instead offering mechanisms that let programmers add those features themselves. The designers focused on making Lua fast, portable, easy to extend, and simple to use as an embedded extension language.
The language was developed by Roberto Ierusalimschy, Luiz Henrique de Figueiredo, and Waldemar Celes at the Pontifical Catholic University of Rio de Janeiro's Computer Graphics Technology Group (Tecgraf). From 1977 to 1992, Brazil enforced strong trade barriers on computer hardware and software, believing the country should produce its own. In that environment, Tecgraf's clients couldn't afford to buy customized software from abroad, and the bureaucratic process to prove local alternatives didn't exist was too complex. So Tecgraf built the basic tools it needed from scratch.
Lua's predecessors were Simple Object Language (SOL) and Data-Entry Language (DEL), two data-description and configuration languages developed at Tecgraf in 1992–1993 to add flexibility to interactive graphical engineering programs for Petrobras. Neither SOL nor DEL had flow-control structures, and Petrobras wanted full programming capabilities. The authors later wrote that in 1993, Tcl was the only real contender for an embeddable language, but it had unfamiliar syntax, poor data-description support, and only ran on Unix. LISP and Scheme were dismissed for their cryptic syntax, and Python was still new. In Tecgraf's do-it-yourself culture, it felt natural to create their own scripting language. Because many potential users weren't professional programmers, the language needed clear syntax and semantics. It also had to be highly portable, since Tecgraf's clients used many different platforms, and it should be provided as a library with a C API, like SOL.
Lua 1.0's object constructors borrowed SOL's data-description syntax (the name Lua means "Moon" in Portuguese, while Sol means "Sun"). Control structures came mostly from Modula (if, while, repeat/until), with influences from CLU (multip
- field
- Programming language design
- known_for
- Lightweight embeddable scripting language with a simple C API
- creators
- Roberto Ierusalimschy, Luiz Henrique de Figueiredo, Waldemar Celes
- institution
- Computer Graphics Technology Group (Tecgraf) at Pontifical Catholic University of Rio de Janeiro, Brazil
- year_created
- 1993
- license
- MIT License (from version 5.0 onwards)
Lore & Background
Lua was created in 1993 by Roberto Ierusalimschy, Luiz Henrique de Figueiredo, and Waldemar Celes, members of the Computer Graphics Technology Group (Tecgraf) at the Pontifical Catholic University of Rio de Janeiro, in Brazil. Its development occurred during Brazil's policy of strong trade barriers for computer hardware and software, which led Tecgraf to implement basic tools from scratch. Lua's predecessors were the data-description and configuration languages Simple Object Language (SOL) and Data-Entry Language (DEL), developed at Tecgraf in 1992–1993 for engineering applications at Petrobras. The lack of flow-control structures in SOL and DEL, and Petrobras's need for full programming power, motivated Lua's creation.
The language's authors considered Tcl as the only real contender for an embeddable language in 1993, but found its syntax unfamiliar, its data description support poor, and its platform limited to Unix. They did not consider LISP or Scheme due to unfriendly syntax, and Python was still in its infancy. Lua 1.0 incorporated the data-description syntax of SOL (hence the name Lua, meaning 'Moon' in Portuguese, while SOL means 'Sun'). Its syntax for control structures was mostly borrowed from Modula, with influences from CLU, C++, SNOBOL, and AWK. The table was developed as the primary data structure, influenced by LISP and Scheme's single data-structure mechanism.
Reader's Guide
Lua's significance lies in its design as a lightweight, embeddable extension language that provides a small set of general features extendable to fit different problem types. It is commonly described as a multi-paradigm language, supporting procedural, functional, and object-oriented programming through mechanisms like first-class functions, lexical scoping, and metatables. The language's compactness—the full reference interpreter is only about 293 kB compiled—and its portability across diverse platforms made it ideal for embedding in applications. Lua's legacy includes its influence on game development, embedded systems, and configuration scripting, where its simple C API allows easy integration. The language's permissive MIT License (from version 5.0) and its design philosophy of providing meta-features rather than paradigm-specific features have contributed to its widespread adoption. Lua's semantics were increasingly influenced by Scheme over time, particularly with anonymous functions and full lexical scoping, while its table-based data structure remains a distinctive and flexible foundation.
Did You Know?
- Lua's name means 'Moon' in Portuguese, while its predecessor SOL means 'Sun'.
- Lua was created under Brazil's market reserve policy, which restricted foreign software imports.
- The language's syntax for control structures was mostly borrowed from Modula.
- Lua's table data structure was influenced by LISP and Scheme's list-based data structure.
Frequently Asked Questions
Who created Lua and where did it originate?
Lua was designed by Roberto Ierusalimschy, Luiz Henrique de Figueiredo, and Waldemar Celes while working in the Tecgraf computer-graphics research group at the Pontifical Catholic University of Rio de Janeiro in Brazil.
What makes Lua different from most other scripting languages?
Rather than trying to be a general-purpose standalone language, Lua is deliberately kept minimal and built to live inside a host application. Its small core exposes a straightforward C interface so that the surrounding program can bolt on domain-specific features without the language itself growing bloated.
When was Lua created and what problem was it meant to solve?
The first version shipped in 1993, at a time when developers increasingly wanted end-users to tweak and extend software without touching the original source code. The team set out to deliver a fast, portable scripting layer that could be dropped into existing C programs with very little overhead.
On what platforms can Lua actually run?
Because the interpreter is written entirely in standard ANSI C, it compiles cleanly on essentially any system that has a C toolchain, from desktop operating systems to embedded devices. Cross-platform portability was one of the original design pillars.
Is Lua open source and under what license?
Yes. Since version 5.0 the language has been released under the permissive MIT License, which lets anyone inspect the source, modify it, or embed it in commercial products with very few legal strings attached.
More in Brazilian inventions 1-24
Spotted an error? Know more?
This is a living reference — every entry is fact-audited, and reader corrections feed straight into our audit queue. Suggest an edit · See this site's audit record
