Custom blocks created as a plugin in a module not showing for Block::load() I have a couple of blocks that have been created using the ... extends BlockBase syntax in my module. They work perfectly fine, and I can add them on the blocks layout page, can add them into DS as a field, etc. They definitely exist fine.

However, when I try and render them using Block::load(), they won't show up, unlike other blocks that work fine.

For example, if I have the following docblock:

/**
 * Provides a 'Cute Cats' Block.
 *
 * @Block(
 *   id = "cute_cats",
 *   admin_label = @Translation("Cute cats yo"),
 * )
 */
 class CuteCats extends BlockBase { ... }


... and then try and call it like this:

$block = \Drupal\block\Entity\Block::load('cute_cats');
return render(\Drupal::entityTypeManager()
  -&gt;getViewBuilder('block')
  -&gt;view($block));


Any idea why? Thanks in advance.
Block::load() loads a configured block, that means a block that is placed in the block layout. It does not load plugins.

The name of the configured block is displayed in the block layout as Machine name.

You can place the block in the Disabled section, if you only want to configure the block, but don't want to show the block in a region.