Skip to main content
Run sandywp push from a local WordPress installation to mirror its database and wp-content into a SandyWP sandbox. This works with Cove, LocalWP, MAMP, XAMPP, and other local stacks.

Before you start

  • Authenticate the SandyWP CLI with sandywp auth login.
  • Start the local WordPress database.
  • Make either wp (WP-CLI) or php available on PATH so the CLI can export the database.

First push

Run the command from the WordPress folder or anywhere below it. The CLI walks upward to find wp-config.php.
The first push creates a new sandbox, restores the local database and wp-content, then writes a .sandywp link file beside wp-config.php. It prints the new public URL and magic login URL. Add .sandywp to .gitignore. It is a local link to one specific sandbox and should not be committed.

Push again

A later sandywp push from the same folder updates the linked sandbox in place. The URL stays the same, but the sandbox database and files are overwritten.
If the linked sandbox was deleted, the CLI can create a replacement and update the link. A failed push leaves the existing sandbox unchanged.

Good to know

Push is one-way: local changes replace changes made directly in SandyWP on the next push. Delete .sandywp when you want the next push to create a new sandbox instead. Subdomain multisite is not supported. Single-site installs and subdirectory multisite networks are supported.

Troubleshooting

For a live source site instead of a local one, use Clone a site. The lower-level import workflow is documented in Imports API guidance.