How to Push Changes from Staging to Live in WordPress Without Overwriting Orders or Comments
In short: pushing a whole staging database to production wipes out orders, comments, form entries, and live edits because WordPress mixes your pages and your customers' activity inside the same tables. Instead of syncing tables, connect staging and live and push only the specific posts, pages, custom post types, or products you edited — leaving live traffic data untouched.
Why staging-to-live syncs wipe out orders and comments
The minute a site goes live, staging and production start drifting apart. While you spend three days rebuilding a landing page on staging, production keeps accepting WooCommerce orders, blog comments, Gravity Forms submissions, new user signups, and quick edits from your content team.
Most host "Push to Live" buttons and database-sync plugins treat staging as the single source of truth. They replace production's database tables with staging's snapshot from three days ago — and anything customers or editors created in the meantime vanishes.
Trying to dodge this by excluding a few tables from the sync rarely holds up either:
- Shared tables: On stores not yet using WooCommerce HPOS everywhere, orders, coupons, and pages all live side by side in
wp_postsandwp_postmeta. You cannot drop or replacewp_postswithout dropping orders, and excludingwp_postsdefeats the push. - Cross-table links: Comments live in
wp_commentsandwp_commentmeta, but point to post IDs inwp_posts. User records and order notes spanwp_users,wp_usermeta, and plugin-specific tables. - Auto-increment collisions: Staging created post ID
4182for your new landing page while production created post ID4182for a customer order or a published blog post. Overwriting by table or raw ID collides immediately.
See our staging-to-production overview for a side-by-side look at full database syncs versus selected-content deployment.
Push only the changed content, not the database
When the change you made on staging is content — a redesigned page, a new campaign post, updated documentation, or refreshed product descriptions — the live database does not need to be replaced at all. Only those specific items need to move.
With PostDeploy's content push pipeline, pushing an item from staging to live works at the WordPress object level, not the SQL table level:
- One signed package per item: Staging packages the post's fields, custom meta, taxonomies, and referenced media into an HMAC-signed JSON payload and sends it to the live site's REST API.
- Media imports first: Images and files used by that page are uploaded to production's media library first, and every URL and Gutenberg block attachment ID is rewritten to production's new IDs — never colliding with live order or post IDs.
- Everything else stays untouched: WooCommerce orders, customer records, comments, form submissions, and unrelated pages are never read, locked, or overwritten.
If your page uses Elementor, Divi, ACF, JetEngine, or WPML, PostDeploy Pro resolves those internal IDs, repeaters, galleries, and translation groups on the live site automatically. If you want to try basic Posts, Pages, and custom post types first, PostDeploy Free on WordPress.org uses the same per-post pipeline.
Step-by-step: pushing staging changes to a live site safely
- Install PostDeploy on both sites and connect them once: Copy the destination site's API key into staging under PostDeploy → Connections (or vice versa if you prefer pulling from live). Use the Test Connection button to confirm reachability before you push.
- Build and review on staging: Edit your pages, custom post types, or WooCommerce product copy on staging while live traffic continues normally.
- Dry-run or push only the ready items: On the staging Dashboard, select the finished pages and click Deploy, or run it from WP-CLI if your workflow is scripted:
wp postdeploy dry-run 4182 --to=production wp postdeploy push 4182 --to=production - Review conflict warnings instead of guessing: If someone edited that same page directly on live since your last push, Pro stops and alerts you rather than silently overwriting their work (see conflict detection in the docs).
- Check the live page — and roll back in one click if needed: Because Pro saves a pre-overwrite snapshot of that single page before updating it, an unexpected layout issue only takes one click on Rollback in PostDeploy → Deployments — or
wp postdeploy rollback <id>— without restoring a full-site backup that would erase recent orders.
Working with clients or a larger team? You can also gate non-admin team members through an approval Queue with agency Deploy Access so editors can stage a push and a lead approves it before it hits live.
The cloned-staging trap: avoiding "-2" duplicates
Most ongoing staging sites start life as a full clone of production. That creates a subtle issue for selective deployment tools: both sites already have the "About" page or "Summer Sale" landing page, even though PostDeploy didn't perform the original copy.
Without clone awareness, pushing an updated version of an existing page from a cloned staging site creates a second post with a -2 slug instead of updating the original. Since PostDeploy Pro 0.9.94, the importer recognizes copies that came from a cloned site and matches them to the existing live post, updating it in place — and subsequent pushes reuse that recorded mapping every time.
When a full sync still makes sense (and when it doesn't)
Selective content deployment doesn't replace every deployment tool. A full staging push — or a tool like WP Staging — is still the right choice before your initial launch, when production has zero live orders or comments yet, or when you are rebuilding a staging copy from production to refresh stale test data.
Once a site is live and taking orders or comments, separate the layers:
- Theme and plugin code: Deploy via Git, Composer, or SFTP.
- Pages, posts, CPTs, and product content: Push only the edited items with PostDeploy.
- Live orders, comments, and user activity: Leave them strictly on production.
Frequently asked questions
Does pushing from staging to live overwrite WooCommerce orders or comments?
No, if you deploy only the changed posts, pages, or products instead of syncing database tables. PostDeploy sends a signed package for the specific items you pick over HTTPS, so live orders, comments, form entries, and customer records are never read or touched.
What if my staging site started as a full-site clone of production?
If you push a page that already existed on both sites from the original clone, PostDeploy Pro 0.9.94 and newer recognizes the cloned copy on the destination and updates it in place instead of creating a duplicate post.
What happens if someone edited the live page while I was working on staging?
Pro checks whether the live post changed since your last push and stops with a conflict warning before overwriting it. Every overwrite also saves an automatic snapshot first, so you can roll back that single page without touching live orders.
When do I still need a full database push instead of a content push?
A full sync makes sense before a site launches, when no real customer orders or comments exist yet, or when you are standing up a brand-new environment. Once traffic is live, code changes belong in Git or SFTP and content updates should be pushed per item.
Try it
PostDeploy Free lets you push Posts, Pages, and custom post types from staging to live without touching your database tables. PostDeploy Pro adds Elementor, Divi, ACF, JetEngine, WPML, WooCommerce product support, conflict detection, and one-click rollback — or see WP-CLI & REST API automation and dev-to-production deployment for more workflows.