أهم النقاط
- A complete backup has two parts: the files and the database.
- Keep at least one copy somewhere other than the server.
- A backup you've never restored is a backup you can't rely on.
What to back up
- Database — posts, pages, users, settings, orders.
- wp-content — uploads, themes, plugins.
- wp-config.php — database credentials and keys.
Option 1: cPanel
- Open Files → Backup.
- Under Partial Backups, download your Home Directory and the site’s MySQL Database.
If your host offers JetBackup, it provides point-in-time copies you can restore with a few clicks.
Files
Databases
Option 2: A backup plugin
Well-known plugins can schedule backups and send them to cloud storage such as Google Drive, Dropbox or S3. Set a schedule (daily database, weekly files) and choose a remote destination.
Option 3: WP-CLI over SSH
cd ~/public_html
wp db export ~/backups/db-$(date +%F).sql
tar -czf ~/backups/files-$(date +%F).tar.gz wp-content wp-config.php
Test a restore
Every few months, restore a backup to a staging subdomain and click through it. That’s the only way to know it works.
الأسئلة الشائعة
How often should I back up?
As often as you can't afford to lose changes. A shop with daily orders needs daily database backups; a brochure site may only need weekly or after edits.
Do I need to back up WordPress core files?
They can be downloaded again, but including them makes restoring simpler. The essentials are wp-content, wp-config.php and the database.