1. Home
  2. Knowledge Base
  3. Getting Started
  4. How to Recover a Broken Block

Because of the way the Gutenberg Block Editor manages blocks there are times when a block may appear broken. This can happen for various reasons the most common reason is because of editing the block as html, if you edit the html of a block then it will show as broken. If for no reason it’s repeatedly happening to you then you should get in contact with the block creator to determine a long term solution. I’ve seen this happen because of plugins that filter/edit the page content on save which introduces code that isn’t part of the block.

What appears is a warning message “This block contains unexpected or invalid content”. And your block will look like the image below in your admin:

It looks like you only have two options and both usually lead you either no content or an html output of code which can’t be edited. But with the latest versions of Gutenberg, there is a very handy hidden tool in Gutenberg that allows you to attempt a block recovery.

FIRST: Make sure you have the latest version of WordPress installed or go and install the Gutenberg plugin.

With the latest version updated/installed go back to your page and click on the more options icon button and choose “Attempt Block Recovery”. That will get the block working again.

I hope that helps!

Was this article helpful?

Related Articles