The Microsoft BASIC, written by Bill Gates and tailored to the MOS 6502 processor, was both a programming language and an operating system substitute for early home computers—laying the foundation for the success of the software giant. Microsoft has now released the original BASIC 1.1 from 1978 under an open-source license.
Excerpt from the program code of the 8080 BASIC written by Paul Allen and Bill Gates (display panel from the New Mexico Museum of Natural History and Science). Gates and Allen wrote the BASIC as a programming language for the Altair 8800, which was based on the Intel 8080 CPU. It was the first software offered by the young company Micro-Soft (later Microsoft), founded by Gates and Allen.
With commands like these, many home computer users of the 1970s and 80s learned programming. Early home computers such as the Apple II, the Atari 400/800 series, or all of Commodore's 8-bit machines, including the Commodore PET from 1977 or the legendary C64, relied on BASIC as the integrated programming language—and, in a sense, as a kind of operating system replacement, as programs were not only written but also launched through it. All these mentioned computers had one thing in common: they relied on 6502 BASIC from Microsoft, tailored to the underlying MOS 6502 CPU!
The company has now released the source code of its 1978 version 1.1 of 6502 BASIC under an open-source license. The assembly code, consisting of approximately 6,955 lines, is now available on GitHub and may be used, modified, and redistributed under the terms of the MIT license.
The Language of Early Home Computers
The BASIC programming language is already over 60 years old and thus older than all the computers mentioned here. However, the historical significance of MOS 6502 BASIC cannot be overlooked, as it was the first touchpoint for many aspiring developers at home to start programming software.
Microsoft produced its first commercial software with a BASIC interpreter tailored for the Intel 8080 processor, offered on paper tape for the first successful home computer, the MITS Altair 8800. Based on this BASIC-80, Bill Gates and Ric Weiland ported the programming language to the MOS 6502 in the summer of 1976. This was largely a direct port of the 8K version of BASIC-80 for the Altair 8800, containing the same prompts for memory size and for enabling floating-point functions (activating them required an additional 135 bytes of memory).
The first machines to use 6502 BASIC were the Ohio Scientific Model 500 and the single-board computer KIM-1 from Commodore in 1977. In the following years, however, the programming language became the foundation for numerous variants that defined the early home computer revolution—including Atarisoft BASIC, Commodore BASIC (PET, VIC-20, C64), and Applesoft BASIC for the Apple II. Through this interpreter, millions of users gained their first access to programming.
The now open-source licensed version 1.1 includes bug fixes and memory management improvements that were developed in 1978 in collaboration with Commodore developer John Feagans. It was later released as "BASIC V2" on the PET and remains present in emulators and museum systems to this day.
Notable is the modular structure of the code: through conditional compilation, different target platforms could be supported with the same codebase—an efficient approach for that time. This allowed systems like the PET, Apple II, or KIM-1 to be addressed.
Bill Gates admitted in 2010 that he (without Commodore's knowledge) included the command WAIT 6502,x as an Easter egg. The Easter egg wrote the word "MICROSOFT!" directly into the screen RAM at address $8000. On the Commodore PET, this coincidentally overwrote the company name Commodore, giving the impression that Gates had specifically targeted the Commodore PET with the joke. The Easter egg exists in the 6502 BASIC on the KIM-1, as well as in the 6809 (CPU) BASIC and the 6800 (CPU) BASIC. Former Commodore employee Jim Butterfield recalls: "Shortly after this implementation, I showed it to Len Tramiel (son of Jack Tramiel) at the Commodore booth at a CES show. He was furious: 'We have a machine with too little memory, and those *!$%$ put something like this in!' The 51 bytes of code were meant to be removed for subsequent machines, but the 10 bytes required to display the message remained in the master copy."
(Image: C64-Wiki.com)
Even small quirks and "signatures" of the developers at the time can be found in the code. These include the hidden labels STORDO and STORD0, as well as the WAIT command personally inserted by Bill Gates, which displays a hidden "MICROSOFT!" on the screen.
Small Footprint, Wide Functionality
Technically, the interpreter was a masterpiece of resource efficiency. The 6502 processor cost around 25 dollars—significantly less than competing CPUs—and had only a few kilobytes of RAM. The BASIC code was written so efficiently that it offered extensive functionality despite tight memory constraints—for that time.
The release is not only interesting for retro-computing enthusiasts. It also enables technical analysis and the understanding of early software architecture during a time when memory space, computing time, and hardware costs were central influencing factors.
With this measure, 6502 BASIC joins a series of historical source code releases from Microsoft—including GW-BASIC, MS-DOS 4.0, and Altair BASIC. The strategic shift toward a more open software culture under CEO Satya Nadella is clearly evident. Today, Microsoft operates GitHub, the world's largest open-source repository—including retrospectives on the origins of its own software history. (sg)
Date: 08.12.2025
Naturally, we always handle your personal data responsibly. Any personal data we receive from you is processed in accordance with applicable data protection legislation. For detailed information please see our privacy policy.
Consent to the use of data for promotional purposes
I hereby consent to Vogel Communications Group GmbH & Co. KG, Max-Planck-Str. 7-9, 97082 Würzburg including any affiliated companies according to §§ 15 et seq. AktG (hereafter: Vogel Communications Group) using my e-mail address to send editorial newsletters. A list of all affiliated companies can be found here
Newsletter content may include all products and services of any companies mentioned above, including for example specialist journals and books, events and fairs as well as event-related products and services, print and digital media offers and services such as additional (editorial) newsletters, raffles, lead campaigns, market research both online and offline, specialist webportals and e-learning offers. In case my personal telephone number has also been collected, it may be used for offers of aforementioned products, for services of the companies mentioned above, and market research purposes.
Additionally, my consent also includes the processing of my email address and telephone number for data matching for marketing purposes with select advertising partners such as LinkedIn, Google, and Meta. For this, Vogel Communications Group may transmit said data in hashed form to the advertising partners who then use said data to determine whether I am also a member of the mentioned advertising partner portals. Vogel Communications Group uses this feature for the purposes of re-targeting (up-selling, cross-selling, and customer loyalty), generating so-called look-alike audiences for acquisition of new customers, and as basis for exclusion for on-going advertising campaigns. Further information can be found in section “data matching for marketing purposes”.
In case I access protected data on Internet portals of Vogel Communications Group including any affiliated companies according to §§ 15 et seq. AktG, I need to provide further data in order to register for the access to such content. In return for this free access to editorial content, my data may be used in accordance with this consent for the purposes stated here. This does not apply to data matching for marketing purposes.
Right of revocation
I understand that I can revoke my consent at will. My revocation does not change the lawfulness of data processing that was conducted based on my consent leading up to my revocation. One option to declare my revocation is to use the contact form found at https://contact.vogel.de. In case I no longer wish to receive certain newsletters, I have subscribed to, I can also click on the unsubscribe link included at the end of a newsletter. Further information regarding my right of revocation and the implementation of it as well as the consequences of my revocation can be found in the data protection declaration, section editorial newsletter.
Future-Proof Authentication with Universal RFID Readers