Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3280450
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T19:42:20+00:00 2026-05-17T19:42:20+00:00

Is it possible to copy to clipboard directly from Vim? yy only copies stuff

  • 0

Is it possible to copy to clipboard directly from Vim? yy only copies stuff to Vim’s internal buffer. I want to copy to the OS’s clipboard. Is there any such command in Vim or you can only yank stuff within Vim?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T19:42:21+00:00Added an answer on May 17, 2026 at 7:42 pm

    The * register will do this. In Windows, + and * are equivalent. In unix there is a subtle difference between + and *:

    Under Windows, the * and + registers
    are equivalent. For X11 systems,
    though, they differ. For X11 systems,
    * is the selection, and + is the cut buffer (like clipboard).
    http://vim.wikia.com/wiki/Accessing_the_system_clipboard

    * is probably what you want most of the time, so I use * because it functions as I expect it to in both environments.

    In Linux distros you have to install vim-gtk (aka gvim) first to gain clipboard functionality. This is because non-gtk vim is typically compiled without X11 support. This is to allow it to run on console only machines (often servers).

    And for those confused about how to use registers when yanking or putting, you merely write " then the name of the register. So for copying something to the clipboard register you type "*y and then to put you type "*p (credit: Kyle Mathews)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there any way to copy all lines from open file to clipboard in
Is it possible to paste (as in copy/paste from the clipboard) a bitmap into
Possible Duplicate: How do I copy a string to the clipboard on Windows using
Possible Duplicate: Clipboard event C# Hi, Can I monitor the clipboard continuously for any
Is it possible to write a binary file directly to the clipboard in .NET?
Is it possible to copy a file from one branch to another unrelated branch
Possible Duplicate: How to programmatically copy/paste in windows phone? how can i use clipboard
Is it possible to create a new local working SVN copy from a specified
Is it possible to copy a single file to multiple directories using the cp
I would like to know if it is possible to copy/move files to a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.