# How to Disable Touchscreen on Wayland

Disabling the touchscreen on a Linux system can be a hassle, especially when you're using the modern and feature-rich Wayland display server. While many online solutions may recommend switching back to the older Xorg server as a workaround, that's hardly an ideal solution. In this blog, we'll present you with a definitive guide that allows you to savor the advantages of Wayland while successfully disabling your touchscreen functionality.

**1\. Identify your touchscreen device.**

The first step is to identify your touchscreen device. You can do this by running the following command in a terminal:

```bash
sudo evtest
```

This will list all of the input devices connected to your computer. Touchscreen devices will be listed as "event\[0-9\]\*".

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1693645054973/48c9c04f-0726-4a0c-b98e-43ca290a89fc.png align="center")

If you do not have the tool installed simply get it from the repository.

```bash
sudo apt install evtest
```

**2\. Create a udev rule to disable the touchscreen.**

A udev rule is a set of instructions that tells the Linux kernel how to handle a specific device.

To create a udev rule to disable your touchscreen, open a text editor and create a new file called `94-disable-touchscreen.rules`. In the file, add the following lines:

```xml
# Disable touchscreen
ACTION=="add|change", KERNEL=="event[0-9]*", ATTRS{id/vendor}=="0eef", ATTRS{id/product}=="c04d", ENV{LIBINPUT_IGNORE_DEVICE}="1"
```

Replace `0eef` and `c04d` with the **vendor** and **product** IDs of your touchscreen device.

You can find these IDs by running the following command:

```bash
# Change the event Number to your touchscreen device
sudo udevadm info --name=/dev/input/event6
```

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1693645433501/129c824a-e2ba-47a9-bc0e-fe61257c55f9.png align="center")

**3\. Save the udev rule file and move it to the /etc/udev/rules.d directory.**

Save the `94-disable-touchscreen.rules` file and move the file to the `/etc/udev/rules.d` directory.

```bash
sudo mv 94-disable-touchscreen.rules /etc/udev/rules.d/
```

**4\. Reload the udev rules.**

Once the file is in the `/etc/udev/rules.d` directory, you need to reload the udev rules. You can do this by running the following command:

```bash
sudo udevadm control --reload
```

**5\. Reboot your computer.**

Finally, you need to reboot your computer. Once your computer has rebooted, your touchscreen should be disabled.
