Skip to content
mutables. vimninja.com

VimNinja · field notes on a Vim course

Vim is a language. Speak it.

VimNinja is an interactive Vim tutorial that teaches Vim the way you’d learn any language: a few words at a time, in real sentences, every day. 82 short lessons on a real Vim engine, on the web and as an extension for Chrome, Edge and Firefox.

The grammar machine n.

Change inside the double quotes.

A small parser written for this page. VimNinja’s own engine runs every one of these on real text, checked against Neovim.

Lesson 1 · The grammar

A verb, then a noun. That’s most of it.

Every Vim command is a small sentence. d is delete, w is a word, so dw deletes a word. Put a number in front and it happens that many times; put i or a before a noun and it means inside or around (VimNinja’s lesson on Vim text objects is all about those two). Learn four verbs and four nouns and you can already say sixteen things:

Four verbs and four nouns, and what each pair says
w a word $ to line end i" in quotes ap a paragraph
d delete dw Delete a word. d$ Delete to the end of the line. di" Delete inside the double quotes. dap Delete the paragraph and the blank line after it.
c change cw Change a word. c$ Change to the end of the line. ci" Change inside the double quotes. cap Change the paragraph and the blank line after it.
y copy yw Copy a word. y$ Copy to the end of the line. yi" Copy inside the double quotes. yap Copy the paragraph and the blank line after it.
gU uppercase gUw Uppercase a word. gU$ Uppercase to the end of the line. gUi" Uppercase inside the double quotes. gUap Uppercase the paragraph and the blank line after it.

Lesson 2 · Two classrooms

The same course, on the web and in your toolbar.

Both run the same Vim engine and the same lessons, and neither needs a terminal.

a The extension · Chrome, Edge, Firefox

A lesson a day, a click away.

VimNinja's daily golf in the extension: a hole played to par, nine keystrokes, with a result to copy
  • Free, no account, and it works offline. More on the VimNinja extension.
  • The toolbar shows how many commands are due for review, and opens the course, Today, Practice and Daily golf.
  • Reminders, if you want them: a time of day, or a nudge when you come back to your computer. At most one a day, and none once today’s practice is done.
  • Private by design: no tracking and no network requests. Your progress stays in the extension on your computer.

Lesson 3 · Contents

From your first i to macros and :g.

Each lesson is a few cards: the idea, a demo the engine plays on real code, an exercise you solve on real code, and a quick recall from memory.

  1. 01 Foundations 6 chapters free
  2. 02 The Vim Way 7 chapters free
  3. 03 Operators 7 chapters Pro
  4. 04 Vertical movement 6 chapters Pro
  5. 05 Search 6 chapters Pro
  6. 06 Text objects 8 chapters Pro
  7. 07 Visual mode 7 chapters Pro
  8. 08 Insert mode power 4 chapters Pro
  9. 09 Registers 4 chapters Pro
  10. 10 Macros 5 chapters Pro
  11. 11 Navigation 5 chapters Pro
  12. 12 Ex & substitution 7 chapters Pro
  13. 13 Real-world refactors 6 chapters Pro
  14. 14 Plugins & your editor 4 chapters Pro

Every lesson, with what it teaches, is on the VimNinja course page.

Lesson 4 · The engine

Not a quiz about Vim. Vim.

Lessons run on VimNinja’s own Vim engine, written for the browser and checked against Neovim. It takes your keys as Vim would, and it talks back.

It understands

Motions, operators, counts, text objects, registers, the dot command, macros, visual block, search and Ex commands.

It reads back

Every command in plain words as you type it (“change inside the double quotes”), and what it’s still waiting for.

It coaches

When there’s a shorter way to do what you just did, it shows you.

It remembers

Every command you practise gets a memory schedule. When one starts to fade, it comes back in the Daily 5.

The keys you learn work in Vim and Neovim, and in the Vim modes of VS Code, JetBrains IDEs and Zed. The last track sets up your own editor.

Your first sentence: ciw.

It means “change the word”. VimNinja has 82 short lessons for the rest of the language.

Start at vimninja.com