Why Neovim Exists

Early in my career, Vim introduced me to text editing with modal editing, commands, and home row typing. But, over time, its technical debt and complex codebase hindered updates.

Neovim began in 2014 as a Vim fork aimed at improving internal structure for faster evolution. It replaced Vim’s synchronous architecture with asynchronous, integrated Lua as a core configuration language alongside VimScript, and added a built-in LSP client. These updates created a plugin ecosystem comparable to modern editors.

Neovim preserves Vim’s speed and flexibility while adding modern workflow infrastructure. If you’re familiar with Vim, it’s a direct upgrade. Beginners get a better foundation and a developer-led ecosystem.

You can get Neovim from the official Neovim website.

What Neovim Does Well

  • Editing text files with speed and precision.
  • Writing and maintaining code with LSP-powered completions, diagnostics, and navigation.
  • Managing files and directories without leaving the editor.
  • Navigating with minimal hand movement through composable keybindings.

Where Neovim Is Not the Right Tool

  • Editing binary files (use a hex editor).
  • Long-form prose (dedicated writing tools handle formatting and focus modes better).
  • Web browsing (use a browser).
  • Process management (use system monitoring tools).

Why Neovim’s Architecture Matters

Asynchronous architecture. Vim runs plugins synchronously by default, so a slow plugin can freeze the entire editor, like a slow car blocking a single-lane road. Neovim’s event loop, however, runs plugins in the background, preventing linting, formatting, and file searching from blocking your typing.

Lua as a configuration language. VimScript was originally meant for simple key mappings but became hard to maintain. Lua is a full programming language with proper data structures and error handling. Most modern Neovim plugins and your configs are written in Lua.

Built-in LSP client. The Language Server Protocol provides IDE features (completions, go-to-definition, rename, diagnostics) for any language with an LSP server. Vim needed external plugins like coc.nvim, but Neovim includes it built-in.

Tree-sitter integration. Traditional syntax highlighting uses regex, which fail on edge cases and can’t understand code structure. Tree-sitter builds a parse tree, providing accurate highlighting, improved code folding, and structural text objects. Unlike regex, which sees lines, tree-sitter recognizes functions, arguments, and control flow.

True color support. Neovim supports 24-bit color, so schemes appear as intended. Syntax themes rely on color contrast to show structure. When terminals reduce colors to 256 or 16, distinctions fade, and themes lose effectiveness.

Common Misconceptions

“Neovim requires weeks of configuration before it’s useful.” Five years ago, sure. Today, distributions like LazyVim provide a ready-to-use IDE in minutes. Start productive and customize later.

“Neovim is only for terminal purists.” Neovim runs within GUI apps like Neovide and integrates into VS Code, with its modal editing model being the main focus, not the terminal.

“You have to choose between Neovim and modern IDE features.” Neovim’s built-in LSP, tree-sitter, and plugin ecosystem offer completions, diagnostics, debugging, and refactoring. The features are available; the key is how you access them.

“lazy.nvim and LazyVim are the same thing.” lazy.nvim is a plugin manager that installs and loads plugins. LazyVim is a distribution—a preconfigured bundle of plugins and settings built on lazy.nvim. You can use lazy.nvim without LazyVim, but LazyVim requires lazy.nvim.

Why Configuration Works the Way It Does

Neovim reads its configuration from a single entry point:

$HOME/.config/nvim/init.lua

Neovim consolidates settings—keybindings, plugins, options—into init.lua, making configurations portable, version-controlled, and easier to debug.

You can keep everything in one file or split it into modules:

require('my_config')

The configuration language is Lua. VimScript was suitable for simple mappings but became fragile as configurations grew complex. Lua resembles a genuine program because it is one.

Plugin management is code; no GUI for browsing or installing plugins. You declare them in your configuration, and a plugin manager handles downloading, updating, and loading. They are central to Neovim, transforming your configuration into a functional editor.

The Plugin Ecosystem

Neovim’s plugin ecosystem is large and sometimes overwhelming.

Think of it like a kitchen: plugins are tools, the plugin manager is the drawer organizer, and a distribution is a fully stocked kitchen. Someone already set up the tools and workflow, so you’re ready to cook from day one.

Three layers:

graph TB A["Plugin Manager\n(handles installing and loading plugins)"] B["Individual Plugins\n(each adds a specific capability)"] C["Distributions\n(preconfigured bundles of plugins + settings)"] C --> A C --> B A --> B

Plugin Managers

lazy.nvim

lazy.nvim is the modern standard. Written by folke, it replaced packer.nvim (now archived) as the community default.

What makes it different:

  • Lazy loading. Plugins load only when needed, keeping startup fast despite dozens installed.
  • Lockfile support. lazy-lock.json pins each plugin to an exact commit, ensuring your config is reproducible across machines.
  • Dependency resolution. Declare dependencies in your spec, lazy.nvim handles load order.
  • Built-in UI. A dashboard shows plugin status, updates, and profiling. Run :Lazy to open it.

If you want full control over your setup, use lazy.nvim.

vim-plug

vim-plug is the veteran. It works in Vim and Neovim, has simpler syntax, and loads all plugins at startup by default.

If your setup works in both Vim and Neovim, use vim-plug. For Neovim-only, lazy.nvim offers more control.

rocks.nvim

rocks.nvim installs plugins via luarocks, the Lua package manager, instead of cloning git repos. Plugins declare dependencies, and version resolution follows standard package management conventions.

The tradeoff: not all plugins publish to luarocks yet, so the catalog is smaller.

Distributions

Distributions give you a working IDE without days of configuration.

LazyVim

LazyVim is the most popular distribution, built on lazy.nvim by the same author.

  • Sensible defaults for most programming workflows.
  • A modular system for language or tool-specific bundles.
  • Clear override points to change behavior without forking config.
  • Excellent documentation with a searchable keymaps reference.

Analyze its choices, then choose what to keep or replace.

kickstart.nvim

kickstart.nvim is a single init.lua file (about 500 lines) with a minimal, documented config. Fork, read, and customize it. Maintained by Neovim core contributor TJ DeVries.

NvChad

NvChad emphasizes aesthetics and performance with a polished UI, custom theme system, and quick startup. It uses its own configuration structure, so customization follows its conventions instead of Neovim’s defaults.

AstroNvim

AstroNvim is community-driven, with settings grouped by “community packs” (language-specific plugin bundles). It offers thorough documentation, and a community-maintained library of shared configurations.

Choosing Your Approach

How much do you want to learn about Neovim’s internals?

  • Maximum learning, maximum control: Begin with a bare init.lua, add lazy.nvim, then install plugins one at a time. It’s slow but educational.
  • Guided learning: Fork kickstart.nvim, read comments, and modify as you go. Working setup on day one.
  • Productive immediately: Install LazyVim or AstroNvim for an IDE-like experience in minutes; customize later.

Started with manual config, then moved to LazyVim, learning more from its source than tutorials.

Command Reference

Quickly find keybindings using the search box.

  • h - Move left
  • j - Move down
  • k - Move up
  • l - Move right
  • $ - Go to the end of the current line
  • ^ - Go to the beginning of the current line
  • G - Go to the end of the file
  • gg - Go to the beginning of the file
  • w - Move to the next word
  • b - Move to the previous word
  • { - Move to the previous line
  • } - Move to the following line
  • Ctrl-u - Scroll up half a page
  • Ctrl-d - Scroll down half a page
  • Ctrl-b - Scroll up one page
  • Ctrl-f - Scroll down one page

Window Commands

  • :new filename - Create a new window (and file if filename provided)
  • :split - Split the window horizontally
  • :vsplit - Split the window vertically
  • :q - Close the current window
  • Ctrl-w s - Split the window horizontally
  • Ctrl-w v - Split the window vertically
  • Ctrl-w w - Cycle through all windows
  • Ctrl-w q - Close the current window

Tab Commands

  • :tabnew - Create a new tab
  • :tabnext - Move to the next tab
  • :tabprevious - Move to the previous tab
  • :tabclose - Close the current tab
  • gt - Move to the next tab
  • gT - Move to the previous tab
  • 1gt - Move to the first tab
  • 2gt - Move to the second tab

File Commands

  • :! mkdir directory - Create a new directory
  • :! touch filename - Create a new file
  • :edit filename - Edit a file
  • :e filename - Edit a file
  • :write - Save the file
  • :w - Save the file
  • :x - Save and exit
  • :exit - Exit
  • :q - Exit
  • gx - Open links under the cursor

Directory Commands

  • nvim . - Open the current directory
  • :pwd - Print the current working directory
  • :cd /path/to/directory - Change the current working directory
  • :Explore - Open the file explorer
  • d - Create a new directory (in Explore)
  • % - Create a new file (in Explore)

Editing Commands

File Operations

  • dG - Delete to the end of the file
  • dd - Delete the current line

Paragraph Operations

  • d( - Delete to the end of the current paragraph
  • d) - Delete to the beginning of the current paragraph

Block Operations

  • d{ - Delete to the end of the current block
  • d} - Delete to the beginning of the current block
  • d/^$ - Delete from the cursor to the following empty line (if cursor is at the start of the block)

Word Operations

  • diw - Delete inner word (only the word, no surrounding spaces)
  • daw - Delete a word (the word and any trailing space)
  • dw - Delete from the cursor to the start of the next word
  • db - Delete from cursor back to the start of the previous word
  • dib - Delete inner “big word” (non-blank delimited WORDs)
  • daB - Delete a “big word” and trailing space

Sentence Operations

  • d[ - Delete to the end of the current sentence
  • d] - Delete to the beginning of the current sentence

General Operations

  • p - Paste the deleted text after the cursor
  • P - Paste the deleted text before the cursor
  • u - Undo the last change
  • Ctrl-r - Redo the last change
  • Ctrl-g - Show the current line and column

Configuration Commands

  • :help runtimepath - Review your config
  • :h rtp - Review your config
  • :checkhealth - Run Neovim’s built-in diagnostics

Tying It Together

Every Neovim decision aims to make the editor programmable and unobtrusive. Async plugins avoid thread conflicts. Built-in LSP enables native language intelligence. Lua ensures maintainable configuration. The plugin ecosystem allows control over programmability.

Neovim is a programmable text editor. Distributions like LazyVim hide complexity with defaults, but programmability remains accessible.

What to Explore Next

Books

  • Practical Vim, a comprehensive guide to Vim/Neovim mastery by Drew Neil.

Practice

  • Run vimtutor in your terminal for an interactive intro to Vim’s editing model.
  • Use Vimaroo, a free browser-based game for practicing Vim motions (works on any platform, including macOS).

Configuration

References