Gutenberg Block
Bannerize includes a native Gutenberg block (wp-bannerize/block) that lets you insert banners directly into the WordPress block editor. This is the easiest way to display banners in posts and pages.
Adding the Block
- Open a post or page in the WordPress block editor
- Click the + button to add a new block
- Search for “Bannerize” or browse the Widgets category
- Click the Bannerize block to insert it
Block Settings
Once the block is added, configure it using the sidebar settings panel on the right:
| Setting | Description | Default |
|---|---|---|
| Numbers | How many banners to display | All banners |
| Campaigns | Filter by one or more campaign slugs | All campaigns |
| Banners | Select specific banners by ID | All banners |
| Order By | How to sort the banners | menu_order |
Order By Options
| Value | Description |
|---|---|
menu_order | Manual order set in the banner editor (drag and drop) |
impressions | Sort by number of impressions (most viewed first) |
clicks | Sort by number of clicks (most clicked first) |
ctr | Sort by click-through rate (highest CTR first) |
random | Random order on each page load |
Examples
Display All Banners
Simply add the block without changing any settings. All published and active banners will be displayed.
Display Banners from a Specific Campaign
- Add the Bannerize block
- In the sidebar, select “holiday-sale” from the Campaigns dropdown
- Set Numbers to
3to limit the display to three banners
Display a Single Banner
- Add the Bannerize block
- In the sidebar, select the specific banner from the Banners dropdown
- The selected banner will be displayed wherever the block is placed
Random Banner Rotation
- Add the Bannerize block
- Set Numbers to
1 - Set Order By to
random - Each page load will show a different banner
Block Preview
The Bannerize block renders a live preview in the editor, so you can see how the banners will look before publishing. The preview respects your campaign and banner selections.
The block preview in the editor does not trigger impression tracking. Impressions are only counted when visitors view the banner on the live site.
Reusable Blocks
You can convert a configured Bannerize block into a WordPress reusable block. This lets you reuse the same banner configuration across multiple posts and pages without reconfiguring each time:
- Click the block options menu (three dots)
- Select Add to Reusable Blocks
- Give it a name (e.g., “Sidebar Campaign Banners”)
- Insert the reusable block anywhere on your site
Block Alignment
The Bannerize block supports WordPress alignment options:
- None — default width
- Wide — extends beyond the content area
- Full Width — spans the entire screen width
- Align Left / Right — floats the block to the left or right with text wrapping
The Gutenberg block requires WordPress 5.0 or higher with the block editor enabled. If you are using the Classic Editor plugin, use the Shortcode method instead.
Scheduling and Limits
The block automatically respects banner scheduling (Date From / Date Expiry) and performance limits (Max Impressions / Max Clicks). Banners that have expired or reached their limits will not appear, even if they are selected in the block settings.