Free course · 34 short lessons · runs in your browser
Learn Rust by building a chat app
One small project, from an empty folder to a chat client that talks to a real AI model. Each lesson teaches one idea from the basics up, then adds it to the project. No experience needed.
Chapter 1 Hello
What a program is, how Rust runs one, and your first Chatterbox greeting.
Chapter 2 Values
Names, numbers, true and false, and text: the things a program remembers.
Chapter 3 Decisions
if, match, loops and functions: teaching Chatterbox to react to what you type.
Chapter 4 Ownership
The idea Rust is famous for, in one picture: one owner, borrowing, and why it saves you.
Chapter 5 Shapes
struct, enum and Option: giving Chatterbox a real Message type.
Chapter 6 Collections
Vec, HashMap and closures: keeping the whole conversation.
Chapter 7 When things fail
Result, the ? operator, modules and files: a Chatterbox that survives bad input.
Chapter 8 The real model
JSON, traits and one HTTP call: Chatterbox talks to a real model.
Learn Rust by building a chat app: frequently asked questions
Is this course free?
Yes. Every lesson and exercise is free, with no account. Progress is stored in your own browser.
Do I need to know how to code?
No. The course starts from what a program is and builds up one idea at a time. If you can already code in another language, the early lessons are quick.
Do I need to install anything?
Not to start. Code boxes compile and run in the page through the official Rust Playground. From chapter 3 you will want Rust on your own machine to run Chatterbox in a terminal; lesson 1.2 shows how.
What will I have at the end?
A working command-line chat program written in Rust that keeps a conversation, saves it to disk and talks to a real AI model, and the Rust fundamentals you used to write it: variables, types, control flow, ownership and borrowing, structs and enums, collections, error handling, traits and one HTTP call.
Are the compiler messages real?
Yes. Every error shown was produced by running the snippet through the Rust compiler during the site build, and the build fails if a snippet stops producing the error it claims.