Backups are not something you think about until you need one, and by then it is usually too late. A server crash, a failed update, a ransomware attack or a simple human error can wipe out years of work in seconds. A good backup strategy is not a luxury but a basic engineering standard for every serious website. In this article we explain how to build a reliable backup system, which mistakes to avoid and how to check that your backups really work when you need them.
Why backup is not the same as hosting redundancy
Many website owners believe they are protected because their hosting provider stores data on multiple disks or offers so-called redundancy. That is a dangerous misconception. Redundancy protects against hardware failure, but not against logical errors. If you accidentally delete a table in your database, that error is instantly replicated to all redundant copies.
A real backup is a copy isolated in time that exists independently of the production system. The key difference is that a backup lets you go back to the state from an hour, a day or a week ago. Redundancy gives you only the current state, including every error that just happened.
- Redundancy protects against disk or server failure.
- Backup protects against human error, attacks, corrupted updates and accidental deletion.
- Versioned backup adds further protection by keeping multiple points in time.
What actually needs to be backed up
A website is not a single file but a system of several components, and each requires a different approach. If you back up only one part, a restore will never be complete.
Database
The database is the heart of a dynamic website. It holds articles, user accounts, orders, comments and configuration. The database should be backed up more often than anything else because it changes almost constantly, especially on ecommerce platforms.
Files and media
This includes images, documents, PDF files, themes and plugins. This data is usually large but changes less often, so an incremental approach that copies only the changes is enough.
Configuration and code
Application code, server settings and configuration files should be under version control, ideally in a Git repository. That is also the cleanest form of backup for everything that does not change through the user interface.
The 3-2-1 rule as the foundation
The most reliable framework for backups is the proven 3-2-1 rule. It is easy to remember and covers almost every realistic data-loss scenario.
- Three copies of your data in total, including the original.
- Two different media or storage types, for example a local disk and the cloud.
- One copy in a physically remote location, outside your primary data center.
The logic is that the risks do not overlap. If there is a fire in the server room, the remote copy stays intact. If the cloud provider has an outage, the local copy saves you. You should never depend on a single point of failure.
If you are thinking about a new or better website for your company, see how we approach website development for clients in Sarajevo and across Bosnia and Herzegovina.
Frequency and retention: how often and how long?
There is no universal frequency that suits every website. You determine the right value based on two questions: how much data you can afford to lose and how quickly you need to be back online. In engineering practice, these two parameters are known as RPO and RTO.
- RPO (Recovery Point Objective) is the maximum period of data loss you can tolerate. If you back up once a day, your RPO is 24 hours.
- RTO (Recovery Time Objective) is the time you need to get the website working again after an incident.
The table below shows general recommendations by website type. These are starting points, not strict rules.
| Website type | Backup frequency | Retention |
|---|---|---|
| Static brochure website | Weekly | 30 days |
| Blog or content portal | Daily | 30 to 60 days |
| Online store with orders | Every few hours or continuously | 90 days or longer |
| Business application | Continuously with daily snapshots | According to legal obligations |
Retention is just as important as frequency. Data corruption or a silent attack can go unnoticed for days. If you keep only the latest copy, you can easily overwrite a good version with a damaged one. That is why it is good practice to keep several older points in time.
Automation and access isolation
A backup that depends on someone remembering to run it manually is not a strategy but a hope. Everything must be automated through scheduled tasks that run without human intervention. Just as important, the backup process needs monitoring that alerts you when a backup fails.
Isolation deserves special attention. If your backups are accessible with the same credentials as the production server, a ransomware attack can encrypt both the original and the backup at the same time. That is why we recommend immutable copies that cannot be changed or deleted for a set period, as well as separate access keys for backup storage.
- Automate with cron jobs or the tools of your hosting environment.
- Encrypt backups both in transit and at rest.
- Use a separate account with minimal privileges for backup operations.
- Set up notifications for failed backups.
The most important step: testing restores
A backup you have never tried to restore is not a backup but an assumption. It is surprising how often backups turn out to be incomplete or corrupted, or the restore process takes unexpectedly long. The only way to be sure is to practice restores regularly in a separate test environment.
We recommend doing a full restore drill at least once a quarter and measuring how long it really takes to get the website running again. Only then do you know whether your actual RTO matches the one you planned. This testing also reveals hidden dependencies, such as server configuration or external services you may have forgotten to include in the plan.
Backup as part of serious development
A good backup strategy is not an afterthought but an integral part of every project’s architecture. When we plan ecommerce development or a business platform, we build the backup system in from the very start, together with monitoring and restore procedures. That is the difference between a website that survives an incident and one that disappears with it.
If you are not sure whether your current data protection is sufficient, or you want to introduce a more reliable backup system, feel free to contact us and we will be happy to assess your setup. Data security is the foundation everything else rests on.

