
The Language card
Make your very own programming language! It can be a serious one, a silly one, or anything in between. How you execute it is up to you!
Make your very own programming language! It can be a serious one, a silly one, or anything in between, and how it runs is up to you.
What counts
Your language should be able to run a program. A good test: can you write FizzBuzz in it? If you can, you’re there! That means it needs some way to keep values around, make decisions and repeat things.
A config or markup format doesn’t count on its own. And renaming the eight Brainf*ck commands to cat noises is very funny, but it’s still Brainf*ck. Put at least one idea of your own in there!
You can write it in whatever you’re comfy with. Python, JavaScript, Rust and C all work great.
How a language works
Most languages go through the same few steps:
- A lexer chops the text up into tokens:
let,x,=,5. - A parser arranges those tokens into a tree (an AST) that shows how they fit together.
- An evaluator walks that tree and actually does the thing.
That’s called a tree-walking interpreter, and it’s the best place to start. Later on, you can turn the tree into bytecode for a little virtual machine of your own, or into another language entirely, like JavaScript or C.
The easiest thing that counts
- A Lisp. Everything is in parentheses, so parsing is almost free and you get to spend your time on the fun parts. Make a Lisp (github.com/kanaka/mal) walks you through it step by step, in pretty much any language.
- A stack language like Forth. Split the code on spaces, push numbers, run words. Tiny, and way more powerful than it looks.
- A small scripting language with variables,
if,whileandprint. Very doable in a week!
Where to learn
Crafting Interpreters by Robert Nystrom (craftinginterpreters.com) is free to read online, and it’s one of the best programming books out there, full stop. The first half builds a tree-walking interpreter in Java, and the second half builds a bytecode VM in C. Even the first few chapters will get you going.
Silly languages are welcome!
Esoteric languages (“esolangs”) are a whole hobby, and esolangs.org has thousands of them. There’s Piet, where programs are abstract paintings, the Shakespeare Programming Language, where they’re plays, and LOLCODE, which is… LOLCODE. If your language’s gimmick makes us laugh and it can still run FizzBuzz, it counts!

This is a whole program! It prints “Hello, World!” in Piet. By Thomas Schoch, CC BY-SA 2.5, via Wikimedia Commons (scaled up).
Going further
- A playground. If your interpreter is written in JavaScript, or compiles to WebAssembly, people can try it right in their browser. This makes the best demo!
- Syntax highlighting. A small VS Code extension with a TextMate grammar makes your language feel real.
- Nice error messages. Point at the exact line and column, and say what went wrong. Everyone who uses your language will love you for it.
- A real compiler. Spit out assembly yourself, or use a backend like QBE or LLVM. If your compiler ends up compiling itself, I’ll be genuinely speechless.
Shipping one
- Demo: a playground in the browser is ideal. Otherwise, link a release with a binary (or explain how to install it), plus a few example programs we can run.
- Screenshot: some code in your language next to its output.
- README: a quick tour of the syntax, some example programs (FizzBuzz, obviously), and how to run them. If you made a design choice you’re proud of, tell us why!
