Skip to content
Snell Rojas

WordPress

Fixing "This block has encountered an error and cannot be previewed" in WordPress

A quick, effective fix for the Gutenberg error “This block has encountered an error and cannot be previewed” in WordPress: clear your browser cache.

Snell RojasPublished Updated 2 min read

I wrote this post in Spanish in 2021 and adapted it to English in 2026.

If you work with the WordPress block editor (Gutenberg), you've probably run into this frustrating message at some point:

"This block has encountered an error and cannot be previewed."

The problem can appear suddenly, for no apparent reason, and interrupt your workflow. In this post I'm sharing a practical fix that worked for me, after trying lots of others without success.

Why Does the "This Block Has Encountered an Error" Message Appear? #

This message is usually related to conflicts in the block editor, caused by:

  • A corrupted browser cache
  • Incompatible plugins
  • Problems with the active theme
  • Errors in the functions.php file

Common Fixes That DIDN'T Work for Me #

Searching Google, I found lots of recommendations, including:

  • Deactivating all plugins
  • Switching themes
  • Adding custom code to functions.php
  • Editing the .htaccess file

However, none of these options solved the problem in my case.

The Fix That Did Work: Clearing the Browser Cache #

After trying several alternatives without success, I noticed that:

  • On my wife's computer, the error didn't show up.
  • In an incognito window, Gutenberg worked without errors.

That made me think the problem was related to the browser cache, and sure enough, after clearing the last 7 days of cache in Google Chrome, the editor went back to working normally.

How to Clear the Cache in Google Chrome #

  • Open Chrome and go to the menu (three vertical dots).
  • Select Settings > Privacy and security > Clear browsing data.
  • Choose the time range: Last 7 days.
  • Check only Cached images and files.
  • Click Clear data.

If Everything Still Fails, You Can: #

  • Edit the block as HTML, and you'll be able to work with it.
  • Update your WordPress version.

The error "This block has encountered an error and cannot be previewed" can have many causes, but before deactivating plugins or editing your theme files, try clearing your browser cache. It's a simple fix and, in many cases, an effective one.