xclip command not found

In this troubleshooting guide we learn how to fix xclip command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

xclip: command not found

or when using sudo you get the following error message

sudo: xclip: command not found

Solutions to xclip: command not found

How To Fix xclip: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu xclip is provided by xclip package.

xclip is:

xclip is a command line utility that is designed to run on any system with an X11 implementation. It provides an interface to X selections (“the clipboard”) from the command line. It can read data from standard in or a file and place it in an X selection for pasting into other X applications. xclip can also print an X selection to standard out, which can then be redirected to a file or another program.

To fix this problem, we can install more using the command below.

sudo apt-get -y install xclip

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install xclip.

sudo apt -y install xclip

Or if you have aptitude installed you can use the following command.

sudo aptitude install xclip

Summary

In this tutorial we learn how to fix xclip command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.