A Release Pipeline for Converted WordPress Themes: Ship Code Without Overwriting Content
By Daniel Carter, Senior AI & Web Development Consultant
Convert2WP – Convert your AI website to WordPress
Moving a website into WordPress does not mean abandoning disciplined software releases. It means deciding which parts remain software and which parts are now editorial data. An AI-generated React project often lives entirely in a repository. A WordPress site usually does not: theme code, plugins, database content, media files and administrative settings have different owners and different change schedules. A release process that treats them as one bundle can overwrite a week's editorial work while successfully deploying a small stylesheet correction.
The right pipeline is often modest. It builds a versioned theme artifact, runs a few meaningful checks and deploys that artifact without replacing production content. This guide describes that approach for a converted AI website. It is not a requirement to introduce an elaborate platform or buy several deployment services. The purpose is to make a routine change predictable, leave an understandable rollback path and avoid relying on someone manually copying files while trying to remember what changed.
Draw the boundary between code and content
Theme templates, custom block source, styles and small site-specific plugins belong in version control. Posts, page revisions, uploaded media and normal editorial changes generally remain in WordPress's content system. Some configuration sits awkwardly between those categories. Declare how it moves instead of assuming a database copy is harmless. A permalink setting, a custom field definition and a page body do not have the same deployment semantics even when all three eventually affect the rendered page.
Block themes introduce another important boundary: editors can customise templates through the Site Editor, creating database-backed overrides of theme files. A new template file may deploy successfully but remain invisible because an existing override takes precedence. Decide which templates editors may customise and how overrides are reconciled when code changes. Do not automatically delete them on every release. They may represent intentional production improvements. Record the source of truth for each shared layout before troubleshooting why a deployed change is not appearing.
Build one artifact and promote that artifact
A reproducible release starts with a known source revision and a locked dependency set. Build the theme's CSS and JavaScript in the release environment, then package only the files needed to run it. Exclude source credentials, temporary exports, development caches and unrelated tooling. Retain the artifact identifier so you can tell which version is installed. Building again separately on each target can produce different outputs if dependencies or configuration change between runs.
Promote the same artifact from a review environment to production after approval. Environment-specific values should be injected through the hosting configuration or another supported mechanism, not baked into a universal theme archive. A staging URL embedded in compiled JavaScript is easy to overlook and difficult for an editor to repair. If an integration genuinely needs different public configuration per environment, document where it comes from and validate that it points to the intended service before exposing the release.
Use checks that match the theme's responsibilities
Start with syntax and packaging checks for the languages and files the theme actually contains. For PHP, linting catches errors that could prevent page rendering. For JavaScript, use the project's supported test and build tools. Validate block registration and the design configuration where applicable. A pure block theme does not need the same test suite as a large custom application. The pipeline should catch plausible failures without adding a ceremony that takes longer than the changes it protects.
Add focused behaviour tests for important custom logic. If the theme contains a calculator, test its rounding and input boundaries. If a plugin transforms imported content, test a representative transformation. Avoid turning every spacing adjustment into a full-site audit. A small browser smoke test can cover the homepage, a standard content page and a page containing the custom block. Keep assertions stable and meaningful so a harmless editorial revision does not cause the software pipeline to fail.
Keep deployment access narrow and traceable
The account performing automated deployment should have only the access needed for that operation. Do not use a personal administrator password as a permanent shared pipeline secret. Prefer the hosting provider's supported deployment mechanism and store credentials in the automation platform's secret manager. Rotate them when ownership changes. Avoid printing environment values in logs while debugging a connection failure. Logs are often accessible to more people than the production account itself.
Record the deployed revision, artifact identifier, time and operator or pipeline run. This is enough to answer a common operational question: did the problem begin with the latest release? Without that record, teams compare memories rather than versions. Restrict who can approve production deployment according to the site's risk. A small brochure site may need one responsible person; a transactional service may need a stronger separation between author and approver. The pipeline should reflect that difference rather than borrowing an unrelated enterprise process.
Move database changes deliberately
A theme release should not normally replace the production database. If a custom plugin needs a new table or stored option, make the change explicit and versioned. Prefer backward-compatible changes when old and new code could overlap during deployment. For example, add a field before requiring it rather than renaming a field while active workers still read the old name. Keep migrations repeatable where possible and record which version has run. Untracked activation hooks are a poor substitute for a planned change process.
Content updates need their own treatment. Importing a revised block pattern may be appropriate, but replacing entire pages can erase editorial changes. Use stable identifiers and narrow updates when an automated content correction is genuinely required. Take a backup before a destructive transformation, and understand whether rollback means restoring data or applying a compensating change. The convenient rollback of theme files does not undo changes made to orders, posts or user records while the new code was active.
Deploy files atomically where the host supports it
Copying a theme file by file can briefly expose a mixed version: new PHP referring to an asset that has not arrived yet, or new JavaScript paired with old styles. Hosts with atomic release directories or supported version swaps reduce this risk. On simpler hosting, choose the documented deployment method and minimise partial-update exposure. Do not improvise file permissions or symlink layouts without confirming that the host supports them. A clever local script can fail under a managed host's restrictions.
Cache handling belongs in the release procedure. A page cache may retain old markup, while a CDN retains an old asset at the same URL. Fingerprinted asset names or deliberate versioning help align markup and assets. Purge the necessary cache layers through supported tools, not by deleting arbitrary directories. Also consider PHP opcode caching if the host's deployment procedure requires invalidation. A release is not complete merely because the files on disk have changed; visitors must receive a coherent version.
Make rollback a bounded operation
Retain the previous known-good artifact and know how to restore it. Define which failure warrants rollback and which can be handled with a small correction. A typography issue is not the same as a PHP error preventing every page from loading. After deployment, inspect a representative public page and the important custom feature. Use safe data and do not submit real business forms just to demonstrate activity. The review should answer whether the release is usable, not claim exhaustive certainty.
Keep the release notes short: the user-visible change, relevant configuration and any data migration. Convert2WP.net can provide a starting point for the visual conversion, while the release process protects the WordPress code you maintain afterward. Minor visual differences can often be refined later with theme settings or a plugin. A reliable code-content boundary is what prevents those refinements from accidentally replacing the work of the people now using WordPress to publish.