Im using Vim 7.3 in Ubuntu and I'm having a little problem copying to the system clipboard with the following command "+y but I'm getting the following error: E354: Invalid register name: '+'

In my vim --version, I see -xterm_clipboard. The option to copy is from mouse right click is also grayed out.

What steps do I need to take to enable the copying of text from my vim to the system clipboard?

3 Answers 3


Trivial problem, sir.

sudo aptitude install vim-gnome

which already comes pre-compiled with the +xterm_clipboard option.

On source-based distros like gentoo, you will have to compile the package with this USE flag specified.


You should see +xterm_clipboard.

The simplest fix is to install a version of vim compiled with clipboard support. In Ubuntu, if you don't wish to build your own, you can install vim-gtk or vim-gnome, both of which have clipboard support.


For Arch Linux, install gvim. This also adds the missing feature to vim.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.