Editable blocks inside the Custom HTML block

In WordPress 7.1, the Custom HTMLHTML HyperText Markup Language. The semantic scripting language primarily used for outputting content in web browsers. blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. supports interleaving static HTML with regular, editable blocks (79115):

<!-- wp:html -->
<div class="banner"><h1>Static heading</h1><!-- wp:paragraph -->
<p>Editable paragraph</p>
<!-- /wp:paragraph --><footer>Static footer</footer></div>
<!-- /wp:html -->

In the editor, the static markup renders inert while the inner blocks are editable in place — but locked: they can’t be moved, removed, or have siblings added. The surrounding structure stays intact. The full markup remains accessible in the “Edit HTML” modal, and serialization round-trips unchanged, so existing content is unaffected.

This also makes block markup a friendlier target for AI tools: a model can generate one Custom HTML block mixing arbitrary markup with editable slots — no custom block, no build step — and the output is immediately safe to edit.

Registering variations as “higher level blocks”

Block variations now accept an innerContent field (79659): an array of static HTML fragments where each null marks the position of the corresponding innerBlocks entry. This lets you ship a fixed markup shell with editable slots as its own inserter item — no custom block needed:

wp.blocks.registerBlockVariation( 'core/html', {
  name: 'testimonial-card',
  title: 'Testimonial Card',
  icon: 'format-quote',
  innerContent: [ '<div class="testimonial-card">', null, '</div>' ],
  innerBlocks: [
    [ 'core/paragraph', { content: 'An inspiring quote.' } ],
  ],
} );

Inserting the variation produces a Custom HTML block with the preset structure and an editable paragraph inside it. Unlike a pattern, the user can edit only the designated slots, not the structure.

innerContent only applies to core/html variations; it is ignored elsewhere.

#7-1, #blocks, #dev-notes, #dev-notes-7-1