Developers · Gutenberg

Error Page block for WordPress

404 / error page section with large decorative error code, heading, description, primary and secondary CTA buttons, optional illustration image, and full background controls.

Get Blockenberg

Free Gutenberg block in Blockenberg. The inspector controls and front-end behavior on this page come from this block’s source, not a shared stub.

Get Blockenberg

What it actually does

404 / error page section with large decorative error code, heading, description, primary and secondary CTA buttons, optional illustration image, and full background controls.

Inspector panels on this block: Content, Illustration, Sizing. Those titles come from index.js, not from a shared template.

Where to find it

Gutenberg inserter → Developers → search “Error Page” (block name `blockenberg/error-page` in block.json). Style it in the sidebar after insert.

How to use Error Page block for WordPress

  1. Install Blockenberg. Install from WordPress.org and activate the plugin.
  2. Insert the block. Edit a page, click +, search for “Error Page”, insert it. Category: Developers.
  3. Configure inspector controls that exist on this block. Open Content. Set “Show Error Code”, “Error Code”, “Primary Button Label”, “Primary Button URL”.
  4. Check the published page. The view script reads HTML data attributes: data-opts. The block editor preview may not run the same view script.

Inspector controls from this block’s code

ControlWhat the code does
Show Error CodeOn/off toggle in the inspector. On by default. Saved as `showError`.
Error CodeText field in the inspector. block.json default: 404. Saved as `errorCode`.
Primary Button LabelText field in the inspector. block.json default: Go to Homepage. Saved as `primaryLabel`.
Primary Button URLText field in the inspector. block.json default: /. Saved as `primaryUrl`.
Show Secondary ButtonOn/off toggle in the inspector. On by default. Saved as `showSecondary`.
Secondary Button LabelText field in the inspector. block.json default: Contact Support. Saved as `secondaryLabel`.
Secondary Button URLText field in the inspector. block.json default: /contact. Saved as `secondaryUrl`.
Show Search BarOn/off toggle in the inspector. Off by default. Saved as `showSearch`.
Show Illustration ImageOn/off toggle in the inspector. Off by default. Saved as `showImage`.
Image Width (px)Numeric range control in the inspector. Range 100–600. block.json default: 360. Saved as `imageWidth`.
Max Width (px)Numeric range control in the inspector. Range 400–1200. block.json default: 700. Saved as `maxWidth`.
Padding Top (px)Numeric range control in the inspector. Range 0–300. block.json default: 100. Saved as `paddingTop`.
Padding Bottom (px)Numeric range control in the inspector. Range 0–300. block.json default: 100. Saved as `paddingBottom`.
Error Code (Typo Code)Shared Blockenberg typography popover (family, size, weight, spacing). Saved as `typoCode`.
HeadingShared Blockenberg typography popover (family, size, weight, spacing). Saved as `typoHeading`.
Body / ButtonsShared Blockenberg typography popover (family, size, weight, spacing). Saved as `typoBody`.
Colors — BackgroundColor control in the inspector. block.json default: #ffffff. Saved as `bgColor`.
Error Code ColorColor control in the inspector. block.json default: #f3f0ff. Saved as `errorCodeColor`.
HeadingColor control in the inspector. block.json default: #111827. Saved as `headingColor`.
Body TextColor control in the inspector. block.json default: #6b7280. Saved as `textColor`.
Primary Button BGColor control in the inspector. block.json default: #7c3aed. Saved as `primaryBg`.
Primary Button TextColor control in the inspector. block.json default: #ffffff. Saved as `primaryColor`.
Secondary Button TextColor control in the inspector. block.json default: #374151. Saved as `secondaryColor`.

What the front-end script actually does

When this is the right block

Notes from the implementation

viewScript: this folder’s frontend.js is enqueued on the front end for this block.

FAQ

How do I add the Error Page block in WordPress?

Install Blockenberg from WordPress.org, edit a page in the block editor, click +, and search for “Error Page”. It sits under Developers. After insert, open Content and set “Show Error Code”, “Error Code”, “Primary Button Label”, “Primary Button URL”.

What makes Error Page different from other Blockenberg blocks?

404 / error page section with large decorative error code, heading, description, primary and secondary CTA buttons, optional illustration image, and full background controls. Inspector labels on this block include “Show Error Code”, “Error Code”, “Primary Button Label”, “Primary Button URL”.

Is the Error Page Gutenberg block free?

Yes. Error Page ships inside Blockenberg. Get the plugin from WordPress.org — no paid add-on is required for this block.

Can I style Error Page to match my theme?

Yes. Blockenberg’s shared typography and color panels apply here, plus any block-specific style controls listed on this page (panels: Content, Illustration, Sizing).

Related developers blocks

Get Blockenberg

Install Blockenberg from WordPress.org, then insert Error Page from the Gutenberg inserter.

Get Blockenberg