Back to Support Content and Media Blocks How to Resolve Block Errors

How to Resolve Block Errors

Occasionally, a block may display an error if it contains content with a formatting problem. This guide will cover a few different ways to fix this if it comes up.

Error Overview

When a block contains a formatting error, it displays the following message:

This block contains unexpected or invalid content.

The error message reads: "This block contains unexpected or invalid content."

This can happen for several reasons including:

Four Options to Solve The Error

The block error message will provide several options to fix the error:

  • Attempt Block Recovery.
  • An ellipsis (three-dot) button containing the options:
    • Resolve
    • Convert to HTML
    • Convert to Classic Block

We’ll explain each of these options below.

The block recovery options are shown, with the ellipses clicked to reveal all options.

Attempt Block Recovery

The editor may be able to restore the block to a version before the error appeared. Click the “Attempt Block Recovery” button to review the block as it was so that you can potentially remove the cause of the error.

Screenshot of an error when a block contains unexpected or invalid content.

Resolve

Click on the ellipsis (three dots) button in the error box to access more options. The first option is “Resolve.”

Screenshot of an error when a block contains unexpected or invalid content. Arrows pointing to the ellipsis (three dots) button and Resolve option from the drop down.

The “Resolve” button attempts to automatically present a block-based solution. It will display the HTML of how it would change the block code. If you are happy with the change, click the “Convert to Blocks” button on the right-hand side.

Screenshot showing that appear when Resolve option is clicked. The two options are Convert to HTML and Convert to Blocks.

Convert to HTML

Click on the ellipsis (three dots) button in the error box to access more options. The second option is “Convert to HTML.”

When you click “Convert to HTML“, this changes the invalid content into an HTML block. This is the same function as the “Convert to HTML” option displayed in the Resolve option above.

Screenshot of an error when a block contains unexpected or invalid content. Arrows pointing to the ellipsis (three dots) button and Conver to HTML option from the drop down.

Convert to Classic Block

Click on the ellipsis (three dots) button in the error box to access more options. The final option is “Convert to Classic Block.”

A Classic block replicates the old WordPress editing experience in the modern WordPress block editor. If the content showing a formatting error was created in the classic editor, you may be able to display the content as intended by converting it to a Classic block.

Screenshot of an error when a block contains unexpected or invalid content. Arrows pointing to the ellipsis (three dots) button and Convert to Classic Block option from the drop down.

If All Else Fails

If none of the above options resulted in a resolution, it may be best to recreate the block from scratch. Block errors don’t show publicly, so you can often visit the public site and copy any text you wish to reuse. As you reconstruct the blocks, pay careful attention to the actions you take, in case one specific action re-introduces the error.

Was this guide helpful for you?

Not quite what you're looking for? Get Help!

Copied to clipboard!