MW
Tutorial

How to Prepare Your Plugin or Theme for WordPress 7.0

A step-by-step compatibility process for shipping a WordPress 7.0-ready release — set up a test site, audit your blocks, fix the breaking changes, and ship with confidence.

intermediate 22 min May 20, 2026
You maintain a WordPress plugin or theme You have read Part 3 of this series on the 7.0 breaking changes

HOW TO PREPARE YOUR PLUGIN OR THEME…

You have seen what WordPress 7.0 changes. This final tutorial turns that into a process: a concrete, ordered set of steps to take your plugin or theme from “untested” to “7.0-ready” — and a checklist to track it.

The process

Set up a WordPress 7.0 test environment

Never test on production. Spin up 7.0 in an isolated environment using one of the official routes: the WordPress Beta Tester plugin (set channel to “Bleeding edge”), a direct download of the release, the WP-CLI updater, or a WordPress Playground instance in the browser for a zero-setup throwaway site. Install your plugin or activate your theme there.

Run your plugin and watch for errors

Turn on WP_DEBUG and WP_DEBUG_LOG. Exercise every major flow — settings screens, blocks, front-end output, REST endpoints, cron tasks. Watch the debug log and the browser console. PHP 7.4 is now the floor, so deprecation notices from old polyfills will surface here too.

Audit your blocks for API version 3

Open every block.json your plugin ships. Confirm "apiVersion": 3. Anything lower means the post containing that block loses the enforced editor iframe — and your block may render or measure differently inside the iframe than outside it. Move to v3 and test each block inside the iframed editor.

Add role:content to content attributes

For every block that can be nested inside a pattern, add "role": "content" to each attribute that represents editable content. Without it, those attributes are hidden in List View and become uneditable inside contentOnly patterns — which are now the default for many patterns.

Bump the PHP requirement and clean up

Set Requires PHP: 7.4 in your plugin or theme header. Delete any polyfills or version branches you kept for PHP 7.2 and 7.3. If a theme declares html5 script theme support, remove it — that value is gone in 7.0.

Test inside the iframed editor specifically

The iframed editor is the single most likely source of a subtle 7.0 bug. Inside the iframe, global styles, third-party scripts, and element measurement behave differently. Open a post with only your blocks, confirm the editor is iframed, and check that toolbars, popovers, and any measurement-dependent UI still work.

Ship the compatibility release

Update the Tested up to: header to 7.0. Write a changelog entry that names 7.0 compatibility explicitly — users and reviewers look for it. Tag the release, push to the plugin repository, and you are done.

The 7.0-readiness checklist

Work through this as you go — your progress is saved in this browser, so you can come back to it.

WordPress 7.0 compatibility checklist

0 / 12

Compatibility

Blocks & patterns

Release

Tick progress is saved locally — close the tab and your state persists.

That’s the series

You now have the complete developer’s picture of WordPress 7.0 — the native AI layer, the modernized dashboard, the breaking changes, the new blocks and design tools, the new developer APIs, and a process to get your own work ready.

WordPress 7.0 is a release that rewards developers who engage with it early. The AI APIs in particular are a foundation that later versions will build on heavily — the sooner you understand them, the better positioned your plugins are. Start with a test site this week.

You've completed this tutorial!

Get the next one in your inbox. Practical tips, no fluff.

Subscribe

Get weekly notes in your inbox

Practical tips, tutorials and resources. No spam.