After years of unofficial copies of Microsoft’s 6502 BASIC floating around on the internet, the software giant has released the code under an open-source license. 6502 BASIC was one of Microsoft’s first pieces of software, adapted in 1976 by Microsoft cofounder Bill Gates and early employee Ric Weiland to run on the 6502 CPU that powered the Apple II, Atari 2600, Nintendo Entertainment System, and Commodore 8-bit series.
Microsoft’s open-source release of 6502 BASIC is a throwback to the initial days of coding, as the software helped standardize programming language implementations and allowed some of the first developers to use a Commodore machine and learn programming by typing 10 PRINT “HELLO” and 20 GOTO 10.
“In 1977, Commodore licensed it for a flat fee of $25,000, a deal that placed Microsoft BASIC at the heart of Commodore’s PET computers and, later, the VIC-20 and Commodore 64,” explains Microsoft in a blog post announcing Microsoft’s 6502 BASIC open source news.
While 6502 BASIC and Microsoft’s other early software projects helped with the development of MS-DOS and established the company’s software licensing business model, interest in this early code and the MOS 6502 CPU is still very much alive nearly 50 years later. Preservationists and hobbyists have been experimenting with FPGA-based re-creations and emulator projects, and the 6502 BASIC code has also appeared in museum archives.
“Over the years, dedicated preservationists have reconstructed build environments and verified that the historical source can still produce byte-exact ROMs,” says Microsoft. “This open-source release builds on that work, now with a clear, modern license. It follows Microsoft’s earlier release of GW-BASIC, which descended from the same lineage and shipped in the original IBM PC’s ROM.“
If you’re interested in experimenting with the assembly language source code of Microsoft’s 6502 BASIC, the complete source code is now available on GitHub.