Raspberry Pie

Grab a screenshot of your RPi project documentation.

If you are working on a Raspberry Pi project and want to take a screenshot for documentation and sharing, you'll have to follow a few important steps. Make sure your Rasperry Pi is connected to the Internet, either through ethernet or Wi-Fi, because you'll need to download a command line application called "Scrot."

If you haven't set up your Raspberry Pi yet, follow our guide to getting started. Once you are set up and ready, follow the instructions below.

How to download and install Scrot

Scrot is a screen capturing application that makes it possible for you to take screenshots by entering a command into Terminal on Raspberry Pi. You can download and install it in Raspbian with a single line of command.

  1. Select Terminal to open a command window. It is the icon in the upper left corner of the screen that looks like a computer monitor.
  2. When Terminal opens, type the following command: sudo apt-get install scrot
  3. Press Enter on the keyboard.

    Installing scrot on Raspberry Pi Scrot will install automatically. You will know whether it worked when Terminal returns the line scrot is installed. If nothing happens, double-check that you entered the command correctly (including spaces and dashes) and try again.

How to take a screenshot

Once installed, taking a screenshot is very easy and only requires one command.

  1. Select Terminal to open a command window. It is the icon in the upper left corner of the screen that looks like a computer monitor.
  2. When Terminal opens, type the following command: scrot
  3. Press Enter on the keyboard.

    Taking a screenshot with the "scrot" command on Raspberry Pi

    You probably won't even realize that it worked. There is no identifying sound or visual aid to let you know that you've taken a screenshot. The image automatically routes into your /home/pi folder.

  4. Select File Manager to see if your screenshot worked. It is the icon in the upper left corner of the screen that looks like a filing cabinet.

  5. Select the folder on the left titled Pi.
  6. Scroll down to the bottom of the folder's contents to identify the screenshots.

    Opening File Manager and the Pi folder on Raspberry Pi

Screenshots will be organized chronologically by date and time in the /home/pi folder.

How to take a delayed screenshot

Of course, the problem with just grabbing an automatic screenshot is that the Terminal window is up and probably in the way of something you were hoping to take a picture of. You can delay the shutter by a specific amount of seconds in order to get your screen in order.

  1. Select Terminal to open a command window. It is the icon in the upper left corner of the screen that looks like a computer monitor.
  2. When Terminal opens, type the following command: scrot -d 10 (where 10 equals the number of seconds you wish to delay the shutter).
  3. Press Enter on the keyboard.

    Delayed screenshot command in scrot on Raspberry Pi

After the designated number of seconds, Scrot will take the screenshot and it will route into the /home/pi folder.

How to reroute where the screenshot ends up

If you'd rather send the screenshots to a specific folder instead of having them land in the /home/pi folder, you can add instructions for where to reroute the images to.

  1. Select Terminal to open a command window. It is the icon in the upper left corner of the screen that looks like a computer monitor.
  2. When Terminal opens, type the following command: scrot /home/pi/pictures/name.png (where pictures is the folder to send the screenshot to and name is the name you give the screenshot).

    You can also reroute it to the Desktop or Documents folder. The end location is up to you.

  3. Press Enter on the keyboard.

    [NOTE] You must include a name for the screenshot and .png at the end or it will fail.

    Rerouting the screenshot with scrot on Raspberry Pi

The screenshot will automatically appear in the new location that you designated.