Skip to content

Push and pull changes

You can copy content in both directions between a live application and its staging copy:

  • Pull (refresh staging): live → staging. Start from the latest live content.
  • Push live: staging → live. Publish what you changed on staging.
  1. Open the Live application.
  2. Click More › Refresh staging from live at the top of the page.
  3. Choose what to copy (see below). Destination application is the staging copy.
  4. Click Refresh staging.

The live application is only read. It stays online the whole time.

The application needs a staging copy first. Without one, the More menu shows Create staging copy instead. See Create a staging copy.

  1. Open the Staging tab.
  2. Click Push to live at the top of the page.
  3. Choose what to copy. Destination application is the live application.
  4. Click Push live.

Under What should be synced?:

  • Application files
  • Database, either Full database or Selected tables. With Selected tables, tick the tables to copy.

You need at least one of the two. On a shop or a site with comments, push only the files, or only the tables you changed, so new orders and comments made on live since the last refresh are kept.

Delete destination files that do not exist on the source controls files that are on the destination but not on the source, such as images uploaded to live after staging was made.

  • On a push it is off by default. Files that exist only on live are kept.
  • On a refresh it is on by default, so staging matches live exactly.

Turn it on for a push only if you really mean to remove those files from live.

  1. A backup first. Netkeel backs up the destination application. It is listed in the destination’s Backups as a Recovery point described as “Automatic backup before push” or “Automatic backup before staging refresh”. The Backups page in the sidebar labels it Before push or Before refresh.
  2. The destination pauses while it is changed. The source keeps running.
  3. Files and the database are copied. The application addresses stored in the copied database are changed to the destination’s address, including in page-builder content.
  4. Caches are cleared on the destination.
  5. The destination is checked. If any step fails, Netkeel puts the destination back as it was.

Some files always stay as they are on the destination and are never copied: the application’s wp-config.php and its object cache files. Each side keeps its own database login and Redis setting.

Each side also keeps its own search engine visibility. Staging is always hidden from search engines, but a push never hides the live site: if Discourage search engines from indexing this site was ticked in WordPress on staging, live keeps its own setting.

Pushes and refreshes of the same pair wait for each other; they never run at the same time.

The sync runs in the background. Follow it in the activity panel.

On the staging copy’s Staging settings, Staging deployment history lists recent runs: Live to Staging or Staging to Live, what was copied, whether it worked, and whether a destination backup was created. The backup is kept with the destination: the live application for a push, the staging copy for a refresh.

Open the live application’s Backups and restore the recovery point described as “Automatic backup before push”. See Restore a backup.