Title: Cannot declare class WP_Widget_Block
Last modified: August 5, 2021

---

# Cannot declare class WP_Widget_Block

 *  Resolved [Peter Wooster](https://wordpress.org/support/users/pkwooster/)
 * (@pkwooster)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/cannot-declare-class-wp_widget_block/)
 * One of my clients got this Fatal error.
 * Cannot declare class WP_Widget_Block, because the name is already in use in …/
   wp-includes/widgets/class-wp-widget-block.php on line 0
 * The cause was an old Gutenberg plugin that was included on her site. I removed
   the plugin and that fixed the site.
 * This was WordPress 5.8 and Gutenberg 6.7.

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/cannot-declare-class-wp_widget_block/#post-14739965)
 * The Block Editor has been built into WordPress since version 5.0.
 * Since then, the Gutenberg plugin is just a testing ground for upcoming features
   and not guaranteed to be stable.
 * If you do not need those upcoming features now, I recommend not using the Gutenberg
   plugin.
 *  Thread Starter [Peter Wooster](https://wordpress.org/support/users/pkwooster/)
 * (@pkwooster)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/cannot-declare-class-wp_widget_block/#post-14741493)
 * Thank you for the clarification. It seems that WordPress tolerated the old plugin
   until version 5.8 (new widget support?). I took a look at her plugins from SFTP
   and immediately removed Gutenberg as I knew it was no longer needed.
 * This post is for all the people who keep posting questions about this specific
   error and getting the usual “disable all plugins” answer. That’s hard to do if
   you don’t have access to the admin. Deletion using FTP or equivalent is all you
   can do.
 * I’m sure you have clients who never maintain their plugins but let their host
   update WordPress. I’m surprised that the host didn’t back off the update as this
   error breaks everything, including the admin.
    -  This reply was modified 4 years, 10 months ago by [Peter Wooster](https://wordpress.org/support/users/pkwooster/).

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Cannot declare class WP_Widget_Block’ is closed to new replies.

## Tags

 * [fatal error](https://wordpress.org/support/topic-tag/fatal-error/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [Peter Wooster](https://wordpress.org/support/users/pkwooster/)
 * Last activity: [4 years, 10 months ago](https://wordpress.org/support/topic/cannot-declare-class-wp_widget_block/#post-14741493)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
