1. Home
  2. Linux
We are reader supported and may earn a commission when you buy through links on our site. Learn more

How to backup Retroarch game saves on Linux

If you play a lot of Retroarch games on your Linux PC, you might be worried about your game saves. Yes, it’s true that Retroarch does a really good job of keeping saves safe, but accidents can happen.

In this guide, we’ll show you how to protect your Retroarch game saves by creating a backup. To get started, make sure you are using the Flatpak or the traditional release of Retroarch (the version you can install through your distribution’s package manager). This guide will not cover how to backup game saves for the Snap release of Retroarch.

Terminal-based backup

One way to back up Retroarch saves and save states is with the terminal and the Tar compression tool. To start the backup process, open up a terminal window by using the Ctrl + Alt + T or Ctrl + Shift + T keyboard combination. Then, once the terminal window is open, use the CD command to move into the Retroarch game saves directory.

If you are using the Flatpak release of RetroArch, use this CD command to move into the saves directory.

cd ~/.var/app/org.libretro.RetroArch/config/retroarch/saves/

Those using the Retroarch app that comes included in the software repository for the Linux operating system they use will need to enter a different CD command.

cd ~/.config/retroarch/saves/

When the terminal session is in the saves directory, you can use the tar command to create a backup of all of the game save files.

tar -czvf retroarch-game-saves.tar.gz *.*

With the compression complete, move the saves to the home directory using the mv command.

mv retroarch-game-saves.tar.gz ~/

After backing up the save files, it is time to back up the save states. Save states are different from save files. Save files are what users create when they use the “save” function in ROM files. Save states are saves created by Retroarch. Using the CD command, move the terminal session into the save states directory.

If you are a Flatpak Retroarch user, you will need to use this CD command to enter into the save state directory.

cd ~/.var/app/org.libretro.RetroArch/config/retroarch/states/

If you’re running the version of Retroarch included in your Linux operating system’s software repository, rather than the Flatpak release of the app, you will need to use this CD command to move into the save states directory.

cd ~/.config/retroarch/states/

Now that the terminal session is inside of the save states directory for Retroarch, make use of the tar command and create a backup of the save state files.

tar -czvf retroarch-game-save-states.tar.gz *.*

When the compression of the Retrorch save states are complete, move the TarGZ archive to your home directory using the mv command.

mv retroarch-game-save-states.tar.gz ~/

After all of the save files and save state files are compressed, open up the Linux file manager and grab both retroarch-game-saves.tar.gz and retroarch-game-save-states.tar.gz and upload them to Dropbox, or place them on a USB flash drive, or other devices for safekeeping.

Restoring the terminal backup

If you need to restore your backup and game saves to your Retroarch installation, open up the Linux file manager, and place the retroarch-game-saves.tar.gz and retroarch-game-save-states.tar.gz TarGZ archives into the home directory. Then, open up a terminal window and enter the commands below

Extract the contents of retroarch-game-saves.tar.gz to the Retroarch game saves directory using the tar command.

For Flatpak users, enter the following Tar command.

cd ~/
tar xvf retroarch-game-saves.tar.gz -C ~/.var/app/org.libretro.RetroArch/config/retroarch/saves/

Those running the non-Flatpak release of Retroarch, execute the following tar command.

cd ~/
tar xvf retroarch-game-saves.tar.gz -C ~/.config/retroarch/saves/

With the game saves restored, it is time to move on to the save states. Using the following tar command, extract the saves backup to the Retroarch save states directory.

Flatpak users, execute the following tar command to restore your save states to the correct directory.

cd ~/ 
tar xvf retroarch-game-save-states.tar.gz -C ~/.var/app/org.libretro.RetroArch/config/retroarch/states/

Non-Flatpak users, run this tar command to restore the Retroarch save states.

cd ~/
tar xvf retroarch-game-save-states.tar.gz -C ~/.config/retroarch/states/

Deja-Dup graphical backup

The terminal backup is an excellent way to back up your Retroarch game saves and keep them safe. However, the backup process is a bit involved and can be tedious if you’re new to Linux. If you’re not a technical Linux user, but still want to be able to create a backup of your game saves in Retroarch, we highly recommend making a backup with Deja-Dup.

Deja-Dup is an excellent tool that will automatically back up all of your configuration files, including Retroarch with no fuss. To learn how to create a backup of your Retroarch game saves with Deja-Dup, please follow this guide on the subject. It goes in-depth on how to create and restore backups with the app.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.