I am trying to disable the touchscreen on my Asus S200E laptop. In Ubuntu 16.04, I was able to do so with this:

Section "InputClass"
    Identifier "evdev touchscreen catchall"
    MatchIsTouchscreen "on"
    MatchDevicePath "/dev/input/event*"
    Driver "libinput"

How can this be done on Ubuntu 18.04?

  • you can use this command xinput disable xinput --list | grep -i "touch " | sed 's/id=//g' | cut -f2
    – naib khan
    Feb 21, 2020 at 4:02

2 Answers 2


It appears that you are referring to files located at /usr/share/X11/xorg.conf.d. Perhaps the libinput driver was recently updated to support your touchscreen?

Probably you want to edit /usr/share/X11/xorg.conf.d/10-evdev.conf with:

Section "InputClass"
    Identifier "evdev touchscreen catchall"
    MatchIsTouchscreen "off"
    MatchDevicePath "/dev/input/event*"
    #Driver "evdev"
    Option "Ignore" "on"

And /usr/share/X11/xorg.conf.d/40-libinput.conf with:

Section "InputClass"
    Identifier "libinput touchscreen catchall"
    MatchIsTouchscreen "off"
    MatchDevicePath "/dev/input/event*"
    #Driver "libinput"
    Option "Ignore" "on"

Note: It's not necessary to make all of the changes. But it potentially saves you from having to go back to reedit files if one of the parameters changes or a bug causes one of them to be ignored.

Note: If only one of the files exist, try editing that one and see if it does what you need. If neither file exists, you may have to create them.

If that does not work (or you don't have permissions necessary to edit system files), get the name of your touchscreen with xinput and add one of the following commands to a startup script:

xinput set-prop [touchscreen name] "Device Enabled" 0
xinput disable [touchscreen name]

Although you can use device and property ids for testing, you should use the names in quotes when adding the commands to scripts. Device id can change between reboots, and property ids are not readable if you need to change the script later.

  • On my Ubuntu 20.04 (HP Elitebook) there is no file /usr/share/X11/xorg.conf.d/10-evdev.conf but there is present the file /usr/share/X11/xorg.conf.d/40-libinput.conf. Editing that disables the touchscreen. The touchpad still works and so does my external mouse.
    – H2ONaCl
    Jan 4, 2021 at 8:59
  • You actually don't need to comment out the driver. The Option does the trick. You may also change MatchIsTouchScreen to off
    – RKatana
    Oct 15, 2021 at 9:39
  • @RKatana Thanks. I'll edit to add info you've provided.
    – xiota
    Oct 16, 2021 at 6:08

It looks like you've already accepted an answer, which is great! For anyone viewing this question still in search of answers, however, I would recommend checking to see if your BIOS has an option to disable the touchscreen. In my case, at least, the Dell BIOS is surprisingly helpful for hardware customization.

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