DB + Files Zip

Updated: Jan 22, 2026
Version: 1.0
Owner: admin

Local Setup Using Virtual Host (Apache)

Step 1: Setup Virtual Host (Required)

First, configure the Apache virtual host:

https://prnt.sc/uD2EkLZcS9aS - see screenshot

Restart Apache after saving the file.


This method creates a complete backup of your WordPress website by exporting the database and compressing all website files into a single ZIP file for safe storage and easy restoration.


Step 1: Import Database (DB)

        1. Login to phpMyAdmin

        2. Create or select the target database

        3. Click Import

        4. Click Choose File and select the .sql fil

        5. Click Go to start the import

 -Import Large Database Using CMD (Windows – WAMP)

Steps

  1. Open Command Prompt

  2. Navigate to the folder where zip_db_name.sql is located
    Example:


    cd D:\projects\database-backups
  3. Run the full MySQL import command:


    D:\Wamp64\bin\mysql\mysql9.1.0\bin\mysql.exe -u root -D db_name -p < zip_db_name.sql
  4. Enter the MySQL password when prompted

  5. Wait for the process to finish



Step 2: Extract Website Files into Local Project Folder (Localhost)

  1. Open your local server directory
    (Example: htdocs for XAMPP, www for WAMP, www for Laragon)

  2. Create or open your project folder

  3. Copy the website ZIP file into the project folder

  4. Right-click the ZIP file → Extract Here

  5. Ensure all WordPress files are inside the project folder


Step 3: Remove SMTP Plugins (Required)
  • Deactivate and delete all SMTP / mail plugins to avoid local email errors.


Step 4: Add Rules at Top of .htaccess

Add the following at the top of .htaccess:


FileETag None RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteRule \.(jpg|jpeg|png|gif|svg)$ http://localhost/download.PNG [NC,R,L]

Step 5: Verify URLs & Database Access

  • Check wp-config.php for correct:

    • Database name

    • Username

    • Password

  • Check wp_options table:

    • siteurl

    • home

    • Ensure both use the correct local URL



Step 6: Update Admin Email (Database)
  • Update admin email directly in the wp_options table if required.


Step 7: Reset Admin Password

  • Change admin user password directly from the wp_users table.

  • Login to WordPress Admin.


Step 8: Save Permalinks

  • Go to Settings → Permalinks

  • Click Save Changes


Step 9: Elementor Fix (If Elementor Site)

  1. Go to Elementor → Tools

  2. Click Sync Library

  3. Click Regenerate Files & Data


Step 10: Save Permalinks Again

  • Go to Settings → Permalinks

  • Click Save Changes again


Step 11: Remove Cache Plugins (Optional)

  • Deactivate and delete cache plugins (not mandatory for local).