Your own coding academy, built from real code.
CodeTrain never writes the code for you.
Try it right here. No account, no install.
Two steps, about a minute, and the first one is going to catch you. Everything here runs for real in your browser. The tutor's replies are pre-recorded, so it knows the handful of ways this lesson usually goes wrong. The real one reads whatever you actually wrote, and it is free for ten lessons a month.
This lesson needs JavaScript to run. With it on, you get a real editor and a Run button right here. You can also run CodeTrain Open Skill locally instead.
Bring the tutor into your own coding agent
CodeTrain Open Skill runs inside the coding agent you already use, on that agent's own model account. You write every line. It sets the steps, gives hints and reviews what you wrote, and it never puts the solution into the lesson.
npx skills add InferHaven/agent-skills --skill codetrainThis needs Node.js 22.20 or later. Other ways to install, including one with no Node.js.
- Free and open source, Apache 2.0.
- Runs in your own agent on your own model account; no CodeTrain account.
- Tested in Claude Code, OpenCode and Antigravity CLI.
No coding agent? Try the live lesson, no account, or start free with ten lessons a month.
Curated courses, and then anything else you ask for
Everything below is a curated course, written by hand so there is somewhere to start. It is laid out like a transit map: a course is a line, each class is a stop along it, and every class is hands-on lessons where you write each small step yourself. You are not limited to this list. Ask for any topic and CodeTrain writes the lesson on the spot, paste any public repo and it teaches you that codebase, or on Pro point it at your own private checkout.
Nothing matches that. Clear the filter, or start free and ask for any topic.
Why this works when a chat window does not
Reading an explanation feels like learning. Producing the code is learning. The whole design is built around making you do the second one.
It refuses to hand you the answer
Ask it to write the function and it will not, no matter how you phrase the request. Stuck learners get a smaller step or the next hint instead. The full rule set is published here, quoted from the prompt it actually runs under.
Every step runs before you move on
You write the line in a real editor and hit Run. Python and JavaScript execute in your browser; bash runs in a sandbox. If it does not pass, the lesson does not advance, so you can never finish something you cannot actually do.
Any public repo becomes the syllabus
Paste a repository URL and say what you want to understand. The lesson is built from the code that is in there today, not from a course someone recorded two years ago. Secrets and gitignored files are refused before they are read.
It brings back what you got wrong
The concepts you fumbled are scheduled to return at widening intervals. One click turns a due concept into a fresh drill built from your actual mistake, not a replay of the lesson you already sat through.
Pricing
Start free, no card. Upgrade when you want your own private repos or your own model key.
- Lessons from any public repo
- 10 lessons / month
- Every live course
- Synced profile + streaks
- CodeTrain Open Skill, forever
- Repo mode: your private repos, through the CLI
- Real labs on real machines
- Fair-use lessons, zero setup
- The larger tutor model tier
- Experimental models from other labs, not just Claude
- Bring your own model key (optional)
- One flat fee per team size, counted in learners
- A lead's dashboard: who can, not who finished
- Onboarding paths built from your own repo
- SSO, audit logs or self-hosting: talk to us about Enterprise
Questions, answered
Fit and learning
Does CodeTrain write code for me?
No, and it is the one rule it will not bend. The tutor's own instructions say the learner writes every line and that it must never write or paste their solution, not even a single line. The full rule set is published here.
Isn't this just ChatGPT explaining my code?
The opposite. Explainers do the work for you. CodeTrain makes you write every line, reviews it Socratically, runs it, and schedules the concepts you did not get to come back as a fresh drill days later. You finish able to do it without help.
How is this different from Copilot or Cursor?
Opposite jobs. Those exist to produce code faster and they are good at it. CodeTrain exists so you can still explain and change that code in six weeks. Most people should run both. Where each one fits, including when not to use us.
What languages does it cover?
Curated courses cover Python, JavaScript, bash and the maths behind LLMs in pure NumPy. Repo mode is not limited to that list: the lesson is built from whatever is in the code you point it at. Browse every course.
How long is a lesson?
A lesson is 2 to 6 steps, sized to the topic, and each step is one small thing you write and run. A step has to run and pass its check before the next one opens.
What happens when I get stuck?
You can ask for a hint or ask the tutor a question. The tutor never writes the line for you; a stuck learner gets a smaller step or the next hint. A step passed with a hint counts as passed with help, not unaided. Concepts you struggled with come back later as a fresh drill.
Plans and limits
Is there really a free version?
Yes, two of them. The managed tutor is free for ten lessons a month with no card. The core tutor is also CodeTrain Open Skill, free and open source, which you can run today and keep forever: it installs into Claude Code and OpenCode, where it was tested, and the docs page covers the install and what leaves your machine.
What does the free plan include?
Ten lessons a month, with no card. Its lessons are built from any public repository or a course, on the website, and the CodeTrain CLI runs them in a fresh scratch folder. A lesson counts against the ten only once it gets somewhere: at least one step passed, or the lesson finished. One abandoned before that, and the guided first lesson, do not count. The ten come back on the first of each month, at midnight UTC.
What does Pro add?
Pro is $24 a month. It adds repo mode, your private repositories through the CodeTrain CLI, real labs on real machines, fair-use lessons, the larger tutor model tier, and your own model key.
Labs and where code runs
Can I use it on my own private repo?
Two ways, depending on what you already use. CodeTrain Open Skill is free and open source, runs inside the coding agent you already have on your machine, and works on the code in front of it, private repositories included. The other way is repo mode in the CodeTrain CLI, which starts on Pro. It is a lesson on the repository you are in: the CLI runs on your machine and works on a copy of the repository, and a change reaches your real repository only when you accept it. CodeTrain never copies or stores your repository on its servers. The Free plan does not give a lesson on your repository: the CLI there runs sandbox lessons in a fresh scratch folder, and website lessons build from a public repository you name, fetched from GitHub by CodeTrain.
What is a lab?
Your own real Linux machine with a broken service on it, or real routers, FRRouting and OpenWrt, and a terminal in the browser. You find what is failing and why, and the fix passes only when the machine itself agrees. Labs are on the Pro and Team plans only.
Can I try a lab without paying?
Yes, with no account. The demo on this page and on the home page has a Systems lab, a simulated Debian machine with Docker, and a Networking tab with a router lesson and a network lab. They run in your browser, simulated, with pre-recorded replies. The real labs run on real machines and routers, and those are on Pro and Team.
Privacy
Can I delete my account and my lessons?
Yes, yourself, at once, from Plan and billing in your dashboard. Deleting erases your lesson history and every piece of code and writing in it, your lab command logs, your saved concepts and review schedule, your learning track data, your profile and your feedback. Usage records kept for accounting and tax are kept without anything that identifies you.
Stop shipping code you cannot explain
Pick a course or paste a repo you have always meant to understand. Free to start, no card.