When taking a screen shot in Ubuntu 22.04 using the PrtSc key, the image is always saved in the ~/Pictures/Screenshots/ directory. However, I generally almost always paste that image to another application and I do not want it to be saved as a file. Besides of filling this directory with unneeded files, I do not want some confidential screen shot information to go to the file system in the first place.

Please note that I am talking about the new "internal" screen shot feature of GNOME 42.x which is activated using the PrtSc key and not the old Screenshot application (gnome-screenshot).

Is there any hidden option to disable or at least change the destination directory? If not, I will have to switch to the old applications like gnome-screenshot or flameshot.

  • 1
    Here is the respective feature request in the issue tracker: gitlab.gnome.org/GNOME/gnome-shell/-/issues/5208 Commented Jul 26, 2022 at 9:33
  • 1
    Sorry for asking here, I'm talking from an Ubuntu 18.04. Does this mean that CTRL+[SHIFT]+PrtSc no longer works in Ubuntu 22.04? Commented Jul 26, 2022 at 20:01
  • @gustavovelascoh You may have to tweak your keyboard shortcuts to make it work.
    – Amanda
    Commented Nov 17, 2023 at 23:13

5 Answers 5


It seems to work for me if I symlink the screenshot directory to /dev/null:

mv ~/Pictures/Screenshots ~/Pictures/Screenshots.old
ln -s /dev/null ~/Pictures/Screenshots

If I do that, the notification that the screenshot is available in the clipboard is not shown anymore. However, the screenshot is still in the clipboard.

  • 3
    A dirty, but easy "solution"! 😈
    – FedKad
    Commented Jul 26, 2022 at 15:48
  • Simple, but so good!
    – borizzzzz
    Commented Jun 19, 2023 at 10:43

You can map printscreen (or any key combo) to this utility called xfce4-screenshooter - you can use it even if you don't use xfce desktop. By default it will ask you what to capture (entire screen, active window, select region etc) and by default it will ask you what to do with the screenshot (save to disk, copy to clipboard etc) but you can add switches to the command that gets executed when you press printscreen. For example, "xfce4-screenshooter -c -f" will take a full screen shot and copy it to the clipboard.

In the mint repositories the package is called xfce4-screenshooter, i'm suspecting it will be the same in all ubuntu variants.


As an alternative to xfce4-screenshooter I could recomment Flameshot. It has lots of "bells-and-whistles", and for me the most useful the ability to finetune the area I wish to copy.

  • That is something that I already use! 👍🏻
    – FedKad
    Commented Aug 2, 2022 at 9:52

Flameshot and xfce4 were not working for me, so after some digging here is what I came up with. From the gnome discussion, here is a simple code that will copy screenshots to clipboard without saving.

While creating a custom keyboard shortcut in settings, add the following code in Command section:

bash -c "gnome-screenshot -af ~/Pictures/Screenshots/_custom_screenshot && xclip ~/Pictures/Screenshots/_custom_screenshot -selection clipboard -target image/png; rm ~/Pictures/Screenshots/_custom_screenshot"

Make sure you have gnome-screenshot and xclip installed.


Another solution, if you don't want a Pictures directory either, is to set XDG_PICTURES_DIR="/tmp" or XDG_PICTURES_DIR="/dev/null" in ~/.config/user-dirs.dirs, since the Screenshots directory is created within the Pictures one.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .