Free tools Windows power users keep installed
One-click scans. No signup required.
iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more
You can handle many inner and around text selections without Tree-sitter. Vim already provides text objects for words, delimiters, quotes, paragraphs, and—when supported by the build—tag blocks. For more punctuation and argument targets, try targets.vim; for a specific pattern, define a custom object with vim-textobj-user. Neovim users can also use nvim-various-textobjs, but pattern-based matches are not a substitute for syntax-aware parsing.
What inner and around text objects select
In Vim-style editing, i generally means the object’s inner content, while a selects the object with its boundary or surrounding context. For example, ci( changes the contents inside parentheses, and da( deletes a parenthesized region. The exact whitespace behavior varies by object: an around object does not always mean only the two delimiters plus the text between them.
Vim’s built-in help documents each object’s behavior individually. Its i( and ib forms select between parentheses; a( and ab include the pair. Similar forms exist for brackets and braces. These objects work with operators such as delete and change, and in Visual mode. Vim help: text objects
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Quote objects have a narrower scope: Vim documents them as working within one line. Escaped quotes are handled according to the quoteescape option. Around-quote selections may include trailing whitespace, or leading whitespace when no trailing whitespace is available. Check the help for the editor and object you actually use rather than assuming every a object behaves alike.
#1 Best Overall
Try Vim’s built-in objects first
For common edits, built-ins may be all you need:
iwandawselect a word, with the inner or around form.i(anda(select within or around parentheses; corresponding forms work with brackets and braces.i"anda", or their single-quote equivalents, select quoted text subject to the one-line and escaping behavior described above.itandatselect inside or around a matched tag block when the Vim build supports the required feature.
These are operator-pending text objects, so commands such as di( delete inside parentheses and ci" change text inside double quotes. The available objects and edge behavior can differ across Vim, Neovim, and Vim-emulation layers; consult the target editor’s own help.
Use targets.vim for more punctuation and argument targets
targets.vim adds families of pair, quote, separator, argument, and tag objects. Its documented examples include cin) for selecting a nearby parenthesis pair and da, for removing an item from a comma-separated list along with a separator, helping keep the remaining list well formed. Configurable mappings support seeking and counts in documented configurations. The project also notes that zero-character matches cannot be visually selected. targets.vim project documentation
This is a useful option when your recurring edits involve punctuation or arguments and you prefer ready-made mappings to writing custom code. Check the project’s current installation instructions and Vim/Neovim compatibility before relying on a particular setup command; those details can change.
Define a custom object with vim-textobj-user
When built-ins and existing plugins do not cover a stable, well-defined text pattern, vim-textobj-user provides a framework for creating text objects. Its documentation describes regular-expression definitions for simpler objects and function-based definitions for more complex ones. Examples include paired << and >> boundaries with separate inner and around mappings, and a line object whose inner form omits indentation. vim-textobj-user project documentation
A pattern or function is only as reliable as the rules it encodes. Test custom objects against nested delimiters, escaping, malformed input, and multiline cases that occur in your files. A regular expression is not a parser, and changes to the text format may require changes to your custom definition.
Consider nvim-various-textobjs for local, pattern-shaped targets
For Neovim, nvim-various-textobjs offers objects including indentation, URLs, and subwords. Its documentation warns that pattern matching can be inaccurate in edge cases; counts are unsupported for most objects, and most characterwise objects do not match multiline regions. It also notes that some filetype-specific pattern objects were deprecated in favor of Tree-sitter-based objects, which can be more precise. nvim-various-textobjs project documentation
Use this kind of collection when the target has a regular, local text shape. It is not a general syntax-aware replacement. If selecting a function, class, or parameter must follow language grammar, nesting, or syntax distinctions, avoiding Tree-sitter may mean accepting narrower coverage or writing and carefully testing a non-Tree-sitter rule. The Neovim Tree-sitter text-objects project documents the parser-based alternative. nvim-treesitter text-objects documentation
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Choose by the object you need
| Option | What it covers or provides | Definition approach | Important limitation |
|---|---|---|---|
| Vim built-ins | Common words, delimiters, quotes, and tags | Editor-provided behavior | Object-specific behavior matters; quote objects are line-limited, and tag support depends on the build. Vim help |
targets.vim |
Additional pairs, quotes, separators, arguments, and tags | Plugin-provided configurable mappings | Zero-character matches cannot be visually selected. Project documentation |
vim-textobj-user |
Custom objects for a specific pattern or behavior | Regular expressions or functions | Custom definitions need testing and upkeep when formats change. Project documentation |
nvim-various-textobjs |
A broad collection of pattern-based Neovim objects, including indentation, URLs, and subwords | Pattern matching | Edge cases and multiline regions may not match as expected; counts are unsupported for most objects. Project documentation |
For basic editing, start with built-ins. Add a plugin when you have a recurring target it already covers; create a custom object when the pattern is stable and the existing choices do not fit. When correctness depends on language syntax rather than nearby text, pattern matching can trade precision for independence from Tree-sitter.
Quick Recap
Best Value
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

