Technology moves fast! ⚑ Don't get left behind.🚢 Subscribe to our mailing list to keep up with latest and greatest in open source projects! πŸ†

Subscribe to our mailing list


A tree explorer plugin for vim.

Star full 4f7b624809470f25b6493d5a7b30d9b9cb905931146e785d67c86ef0c205a402Star full 4f7b624809470f25b6493d5a7b30d9b9cb905931146e785d67c86ef0c205a402Star full 4f7b624809470f25b6493d5a7b30d9b9cb905931146e785d67c86ef0c205a402Star full 4f7b624809470f25b6493d5a7b30d9b9cb905931146e785d67c86ef0c205a402Star full 4f7b624809470f25b6493d5a7b30d9b9cb905931146e785d67c86ef0c205a402 (1 ratings)
Rated 5.0 out of 5
Subscribe to updates I use nerdtree

Statistics on nerdtree

Number of watchers on Github 9444
Number of open issues 151
Average time to close an issue 3 months
Main language VimL
Average time to merge a PR about 1 month
Open pull requests 40+
Closed pull requests 41+
Last commit about 1 year ago
Repo Created about 11 years ago
Repo Last Updated about 1 year ago
Size 1.28 MB
Organization / Authorscrooloose
Page Updated
Do you use nerdtree? Leave a review!
View open issues (151)
View nerdtree activity
View on github
Fresh, new opensource launches πŸš€πŸš€πŸš€
Trendy new open source projects in your inbox! View examples

Subscribe to our mailing list

Evaluating nerdtree for your project? Score Explanation
Commits Score (?)
Issues & PR Score (?)

The NERDTree


The NERDTree is a file system explorer for the Vim editor. Using this plugin, users can visually browse complex directory hierarchies, quickly open files for reading or editing, and perform basic file system operations.

This plugin can also be extended with custom mappings using a special API. The details of this API and of other NERDTree features are described in the included documentation.

NERDTree Screenshot



git clone ~/.vim/bundle/nerdtree

Then reload Vim, run :helptags ~/.vim/bundle/nerdtree/doc/ or :Helptags, and check out :help NERDTree.txt.


apt-vim install -y


Is there any support for git flags?

Yes, install nerdtree-git-plugin.

Can I have the nerdtree on every tab automatically?

Nope. If this is something you want then chances are you aren't using tabs and buffers as they were intended to be used. Read this

If you are interested in this behaviour then consider vim-nerdtree-tabs

How can I open a NERDTree automatically when vim starts up?

Stick this in your vimrc: autocmd vimenter * NERDTree

How can I open a NERDTree automatically when vim starts up if no files were specified?

Stick this in your vimrc:

autocmd StdinReadPre * let s:std_in=1
autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endif

Note: Now start vim with plain vim, not vim .

How can I open NERDTree automatically when vim starts up on opening a directory?

autocmd StdinReadPre * let s:std_in=1
autocmd VimEnter * if argc() == 1 && isdirectory(argv()[0]) && !exists("s:std_in") | exe 'NERDTree' argv()[0] | wincmd p | ene | endif

This window is tab-specific, meaning it's used by all windows in the tab. This trick also prevents NERDTree from hiding when first selecting a file.

How can I map a specific key or shortcut to open NERDTree?

Stick this in your vimrc to open NERDTree with Ctrl+n (you can set whatever key you want):

map <C-n> :NERDTreeToggle<CR>

How can I close vim if the only window left open is a NERDTree?

Stick this in your vimrc:

autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif

Can I have different highlighting for different file extensions?

See here:

How can I change default arrows?

Use these variables in your vimrc. Note that below are default arrow symbols

let g:NERDTreeDirArrowExpandable = ''
let g:NERDTreeDirArrowCollapsible = ''
nerdtree open issues Ask a question     (View All Issues)
  • over 2 years lookupfile can't work on gvim(windows), after changing CWD by NERDtree
  • over 2 years 'x' closes tree higher than it should
  • over 2 years Same file on multiple tabs support
  • over 2 years OpenBookmark error - Windows 10
  • over 2 years If my file name contain `$` ,it will show no match
  • over 2 years Attempting to open file with special characters fails
  • over 2 years Create file (m ↦ a) does not trigger BufNewFile
  • over 2 years E716:Key not present in Dictionary: CreateTabTree
  • over 2 years Bad opening with bookmarks
  • over 2 years File coloring based on variable property
  • over 2 years Not opening dir the first time, and skipping to next dir, when using enter.
  • over 2 years Nerdtree seems to cause Python to crash on mac
  • over 2 years Auto-expand GUI window by NERDTreeWinSize
  • over 2 years How to disable a NERDTree mapping that conflicts with a custom mapping?
  • almost 3 years can't check arrow char in mingw32
  • almost 3 years function nerdtree#openExplorer undefined
  • almost 3 years Feature Request: Visual selecting node to move to
  • almost 3 years Error detected while processing /home/world/.vim/bundle/nerdtree/lib/nerdtree/tree_dir_node.vim
  • almost 3 years Saving a file causes error
  • almost 3 years BufLeave and BufEnter event not getting triggered when re-entering the same buffer from NERDTree
  • almost 3 years "3 file(s) could not be loaded into the NERD tree" on Windows gVim
  • almost 3 years Use git mv when moving files
  • almost 3 years E86: Buffer 1 does not exist
  • almost 3 years [feature request] Add hotkey for lcd (buffer local cd)
  • almost 3 years Cannot create node in path with accented characters
  • almost 3 years readme: add screenshot
  • about 3 years Feature request: open in multiple buffes or windows (tabs) with visual-line mode support
  • about 3 years Documentation for keybinding API?
  • about 3 years wildignore integration acts funny
  • about 3 years How to colorize executable files with different extensions?
nerdtree open pull requests (View All Pulls)
  • Make window creation command configurable
  • Issue #537: Fix dir arrows not functioning properly
  • changed arrows for NERDTreeDirArrowExpandable and NERDTreeDirArrowCol…
  • Fix #520 E716: Key not present in Dictionary: setShowHidden
  • Add support for natural sorting order.
  • update api call to open directory tree in window
  • Don't require user to type 'yes' to delete an empty directory
  • Add bdelete functionality
  • Option create tab at the end
  • NERDTreeFind takes an optional filename argument
  • Added NERDTreeNoSwitchTabs option.
  • New configuration option: NERDTreeActivateFileMode
  • Don't ignore autocmd events when close tree
  • Add "search filter" functionality
  • Add support for copy on Windows systems
  • Ignore .. and . special dirs regardless of the NERDTreeShowHidden option
  • A settings to hide symlink label decorator
  • fix about windows UNC paths.
  • Ensure NERDTreeFile syntax group is matched when using NERDTreeDirArrows
  • ability to "lynx-like" motion
  • Added horizontal rules to FAQ section in readme
  • Add option to disable collapsing of directory names
  • Allow user-defined read-only indicator.
  • Suppress autocmds less aggressively
  • Read-only files opening fix
  • Remove empty segments
  • Expose initNerdTreeInPlace
  • Save people time
  • Use fnameescape to quote filenames for :badd.
  • [docs] faq: how to start with open nerdtree but main window focused
  • added NERDTreeFocusClose command
  • New option: NERDTreeShowExecutableFlag
  • Determine if we're running in Cygwin on Windows.
  • correct NERDTreeIgnore pattern in doc
  • Use relative path with globpath
  • Update NERD_tree.vim
  • Added help info and shortcut in readme
  • Update fs_menu.vim
  • Added back WinEnter and WinLeave to eventignore in nerdtree#exec(cmd)
  • Fix error if not in UTF-8
nerdtree questions on Stackoverflow (View All Questions)
  • How to jump back to NERDTree from file in tab?
  • How to install nerdtree plugin on linuxmint for vim74
  • changing root in NERDTree
  • how can I show hidden files (starting with period) in NERDTree?
  • vim NERDTree key mapping
  • Vim: set background color for non-textedit windows (NERDTree or Tagbar for example)
  • Check whether in NERDTree
  • Is there a NERDTree or other project plugin for vim that integrates with git to show the status of files?
  • vim NERDTree show .git folders and files
  • How to scroll from vim buffer to NERDTree file?
  • NERDTree reload new files
  • How to open NERDTree without focusing it
  • nerdtree and mvim, how to get it to open to a split screen
  • How to open a file in new tab by default in NERDTree?
  • vim:how to set taglist and nerdtree at one vertical split screen
  • NERDTree gives error "x file(s) could not be loaded into the nerdtree"
  • Difference of o and go in NERDTree
  • Prevent grep results opening in NerdTree window
  • One mapping to toggle NERDTree and open to current file when toggling on
  • Vim NERDTree + tagbar not working as expected
  • Ack with NerdTree
  • How to recover file deleted with NerdTREE
  • how to refresh in nerdtree plugin
  • NERDTree toggling and keyboard mapping
  • Vim NERDTree. How to prohibit duplicate files in tabs?
  • Using NERDTree as Vim sidebar
  • Two basic questions with NERDTree β€” switching windows and finding files
  • NERDTree open in a new tab, as last tab in gvim?
  • How to make NERDTree always open on the right side?
  • NERDTree: what does a starred/bold file indicate?
nerdtree list of languages used
  • Vim script
Other projects in VimL