Introduction
Backing up your Mikrotik router’s configuration is essential for disaster recovery, migration, or just ensuring that changes to your network settings can be undone if something goes wrong. In this article, we will guide you through different methods for backup and restoring the configuration of your Mikrotik device using both the RouterOS web interface and command line.
Why Backup Your Mikrotik Configuration?
Regular backups help you avoid losing valuable settings after a reset, accidental misconfiguration, or hardware failure. With a proper backup, you can quickly restore your router to its operational state without reconfiguring everything manually.
IMPORTANT – Certificates
Certificates are not included in the backup created using the /system backup save
command!
To back up certificates and other custom files, you need to export them separately. You can use the following command to export certificates:
/certificate export-certificate [certificate-name] file-name=my-cert
If you need to restore certificates later, you’ll have to upload and import them manually:
/certificate import file-name=my-cert
Video Tutorial How to Backup Mikrotik Configuration
Method 1: Backup Using WinBox or Web Interface
More information about Winbox find on the link.
- Login to Mikrotik Router
Open WinBox or access the Mikrotik router via a browser. Login using your admin credentials. - Navigate to Files Menu
Once logged in, locate the “Files” option on the left sidebar menu. - Create Backup
In the Files window, click on the “Backup” button. A dialog will appear allowing you to name the backup file. You can choose whether to encrypt the backup file with a password for added security. Click “OK” to proceed. - Download the Backup File
After the backup is created, you will see the new file listed in the Files window. Right-click the file and select “Download” to save the backup file to your local machine. - Store the Backup
Save the file to a secure location where you can retrieve it if needed.

Method 2: Backup Using Command Line (CLI)
For users comfortable with the command line, you can quickly create a backup by executing commands via SSH or the Mikrotik terminal.
- Login via SSH or Terminal
Access the router’s CLI via SSH or using the built-in terminal in the RouterOS interface. - Create Backup
Run the following command to create a backup:/system backup save name=my-backup
- This will save the backup as a file named
my-backup
.
- This will save the backup as a file named
- Download the Backup
Once the backup is complete, download it using an SCP (Secure Copy) tool or by navigating to the web interface’s “Files” section as described earlier.
Automating Backups with Scripts
To automate backups, you can create a script and schedule it to run at regular intervals.
- Create a Script
Open a new terminal session and create a script:/system script add name=backup-script source="/system backup save name=auto-backup"
- Previous backup will be overwritten!
- Schedule the Backup
/system scheduler add name=backup-schedule interval=1w on-event=backup-script
- This will run the script every week to create a backup file. Previous backup will be overwritten!
Restoring the Backup
In case you need to restore the configuration from the backup, follow these steps:
- Access the Files Menu or CLI
In WinBox or Web Interface, go to the Files section and upload the backup file. Alternatively, using the CLI, upload the file via SCP. - Restore the Configuration
Run the restore command:/system backup load name=my-backup
- After restoring, the router will reboot with the restored settings.