Blocks is a free WordPress plugin that lets you create reusable content blocks and embed them anywhere on your site with a shortcode. You write a piece of content once — a call to action, a disclaimer, an announcement, or a support notice — and paste its shortcode into any page, post, widget area, or page builder module where you want that content to appear.
When you update the block in one place, every instance on your site updates automatically. As a result, you never have to hunt down and manually edit the same text across dozens of pages. Beyond reusable blocks, the plugin now includes site variables, export and import, site info shortcodes, popups and banners, and a security and performance toolkit — all in one lightweight plugin.
Furthermore, Blocks is available for free on WordPress.org and works with any WordPress theme and every major page builder.
What Are WordPress Content Blocks?
WordPress content blocks (in the context of this plugin) are reusable pieces of content stored as custom post types. Each block has its own editor page where you write the content, and the plugin generates a unique shortcode for that block. You then paste the shortcode wherever you need the content to appear.
This is different from Gutenberg blocks. Gutenberg blocks are the building blocks of the WordPress block editor — they structure individual pages. The Blocks plugin, on the other hand, creates reusable content snippets that live independently and can be embedded anywhere via shortcode — including the Classic Editor, widget areas, theme files, and page builders that Gutenberg patterns cannot reach.
Why Use Reusable Content Blocks?
Without reusable content blocks, maintaining consistent content across your site is a manual process. With the Blocks plugin, you solve several common problems:
- Consistent messaging — your call to action or disclaimer is identical everywhere it appears. You eliminate the risk of outdated or inconsistent versions on different pages.
- Single point of editing — update once, update everywhere. Changing a phone number, a pricing detail, or a legal disclaimer takes seconds instead of hours.
- Non-technical management — anyone who can edit a WordPress post can create and update blocks. No code, no theme editing, no page builder knowledge required.
- Widget-area content — place blocks in sidebars, footers, and other widget areas using a text widget with the shortcode.
- Visibility control — show a block to everyone, only to logged-in users, only to logged-out visitors, or only to administrators. One setting per block, no extra plugin.
- Organized libraries — categories and tags keep large block collections manageable, and one-click duplication speeds up variations.
In short, the Blocks plugin turns any piece of content into a centrally managed, reusable asset.
How the Blocks Plugin Works
The workflow is straightforward:
- Create a new block — go to Blocks > Add New in your WordPress admin.
- Write the content — use the standard WordPress editor. You can include text, HTML, images, other shortcodes, and variables.
- Copy the shortcode — the plugin generates a shortcode like
[block id="123"]on the block’s edit page. - Paste the shortcode — add it to any page, post, widget area, or page builder module.
- The content renders — WordPress replaces the shortcode with your block content when the page loads. Renders are cached automatically, so blocks add no measurable overhead.
Site Variables: Define Once, Use as {{blocks:token}} Anywhere
Site variables are the newest addition to Blocks. A variable is a value you define once — a phone number, a support email, a price, a promo code — and reuse anywhere as a {{blocks:token}}. Put {{blocks:phone}} or {{blocks:support_email}} inside any block, popup, or banner, and when the value changes you update it in exactly one place. Every page, in every builder, updates instantly.
In addition to your own variables, Blocks ships built-in tokens that read from your site settings:
- Contact —
{{blocks:phone}},{{blocks:phone_plain}}(digits only, fortel:links),{{blocks:email}},{{blocks:company_name}},{{blocks:address}} - Social profiles —
{{blocks:facebook}},{{blocks:twitter}},{{blocks:instagram}},{{blocks:linkedin}},{{blocks:youtube}} - Site identity —
{{blocks:site_title}},{{blocks:tagline}},{{blocks:site_url}} - Dynamic dates —
{{blocks:year}},{{blocks:month}},{{blocks:today}}— a copyright line that says© {{blocks:year}} {{blocks:company_name}}never goes stale again.
You can also print a single variable directly in any content with the standalone shortcode:
[blocks var="support_email"]
Variables are managed on a dedicated admin page that lists every built-in token with its current value, so you always know what will render. Unknown tokens render as empty text — a typo never leaks a literal token onto your live site.
By default, tokens resolve inside Blocks content (blocks, popups, banners). Turn on resolve variables everywhere and they also work typed directly into regular post content, widget areas, and any page builder’s text elements — Gutenberg, Elementor, Divi, Bricks, Beaver Builder, WPBakery, Oxygen, Breakdance, Thrive, Zion, and Fusion. Only {{blocks:...}} tokens are ever touched, so JavaScript templates and other plugins’ tags are never altered.
Export and Import: Move Blocks Between Sites
The Import / Export page packs every block — content, status, categories, and tags — together with all your site variables into a single JSON file. Import that file on any other WordPress site running Blocks and your content library comes with you.
- Backups — keep a versioned snapshot of your reusable content, independent of database backups.
- Staging to production — build and review blocks on staging, then import them to the live site in one step.
- Agency workflows — maintain a starter library of blocks and variables, and seed every new client site from it.
Imports are safe by design: blocks are matched by title, existing blocks are never overwritten unless you explicitly choose to, and malformed files are rejected outright.
Site Info Shortcodes
Blocks centralizes your business details — company name, phone, email, address, social profiles, logo, and favicon — on one settings screen, and exposes each of them as a shortcode:
[blocks field="phone"]
[blocks field="email_link"]
[blocks field="address"]
[blocks field="logo" size="medium"]
Formatted variants are built in: phone_link produces a ready tel: URL, email_link a mailto: URL, and phone_plain strips formatting to digits. Consequently, contact details live in one place and render consistently in headers, footers, contact pages, and structured data.
Popups and Announcement Banners
Any block can become a popup or a site-wide banner — no separate popup plugin required.
- Popups — trigger on a time delay or scroll depth, with a configurable overlay color and opacity, close button, click-outside and Escape-key closing, and a cookie that stops repeat displays for a number of days you choose.
- Banners — pin a block to the top or bottom of every page. Banners support sticky positioning, dismissal with a cookie, background blur and opacity, custom colors and sizing, and an optional live countdown timer for time-limited announcements.
Because popups and banners are just blocks, they support HTML, nested shortcodes, and variables — and you edit them from the same place as everything else.
Structured Content Types
Beyond free-form blocks, the plugin ships four optional content types — each individually toggleable, so they only exist if you use them:
- FAQs — manage questions and answers as posts and render them with
[blocks-faqs]. - Features — maintain a product feature list and render it as a list (
[blocks-features]) or a comparison table ([blocks-compare]). - Glossary — build a terms glossary with its own archive.
- Release notes — publish version history and render it with
[changelog]. The release history at the bottom of this very page is rendered by that shortcode.
Support Hours and Live Chat
Blocks also handles the “are we open?” problem. Set your support hours once, display them with [blocks-hours], and integrate the live chat provider you already use — Olark, Crisp, or Tawk.to — loaded the right way and aware of your business hours. A small REST API exposes the same information to any JavaScript on your site.
Security Hardening and Performance
The plugin includes a curated set of hardening and performance toggles — every one of them off by default, so Blocks changes nothing until you ask it to:
- Security headers — HSTS with a configurable max-age.
- Fingerprint removal — hide the WordPress version, generator tags, and asset version strings that scanners use to target known exploits.
- Attack surface reduction — disable XML-RPC, RSD, shortlinks, oEmbed discovery, and feeds you do not use.
- Login protection — a custom branded login page, an optional hidden login URL, and complete comment-system removal for sites that do not need comments.
- Anti-spam for Contact Form 7 — an invisible honeypot field plus a time-to-submit check that stops bots without CAPTCHAs, and a keyword filter for spam patterns. Pairs well with the CF7 Mailchimp Extension.
- Performance — dequeue emoji scripts, embeds, and other assets you do not use; add
preconnectresource hints for the origins you do; enable Speculation Rules for near-instant navigation on modern browsers. - Housekeeping — limit post revisions, allow safe SVG uploads, enable aggressive automatic updates, and redirect idle logged-in sessions.
Each toggle is independent. Enable the three you need; ignore the rest.
Works With Every Page Builder
Because a block renders through a plain shortcode, it works anywhere WordPress renders content. Beyond that, Blocks ships a dedicated Block element for eleven editors and builders — search for “Block” in your builder’s element panel, drop it in, and pick a block from the Select Block dropdown. No shortcode to remember, no ID to look up.
How to Add a Block in Each Builder
| Builder | How to use it |
|---|---|
| Gutenberg (block editor) | Open the inserter, search for Block, add it, then choose your block in the sidebar settings panel. |
| Elementor | Search the widget panel for Block, drag it into your layout, and pick a block from the Select Block dropdown in the Content tab. |
| Bricks | Add the Block element from the elements panel and choose a block in Select Block. Works in headers, footers, and templates too. |
| Divi | Insert the Block module, then choose which block to display from the module’s Select Block setting. |
| Beaver Builder | Find the Block module under the Basic group, drop it into a row, and select your block in the General tab. |
| WPBakery | Add the Block element from the Content category and pick a block from the dropdown. |
| Oxygen | Insert the Block element and choose a block from Select Block in the element options. |
| Breakdance | Add the Block element and pick a block from the Select Block dropdown. |
| Thrive Architect | Drag in the Block element and select which block to render from its options panel. |
| Zion Builder | Add the Block element and choose your block from the Select Block option. |
| Fusion Builder (Avada) | Add the Block element in Fusion Builder and pick a block from the select field. |
Or Use the Shortcode — It Works in All of Them
Every builder above (and any builder not on the list) also renders the plain shortcode. Paste it into any text, rich text, code, or shortcode module:
[block id="123" title="Footer CTA"]
In theme template files, render a block with PHP:
<?php echo do_shortcode( '[block title="Footer CTA"]' ); ?>
And with resolve variables everywhere turned on, you can type tokens like {{blocks:phone}} straight into any builder’s text element — Blocks replaces them server-side, so the builder never needs to understand them.
This is also your escape hatch: content stored in Blocks survives theme changes and builder migrations. Move from Elementor to Bricks, or from a builder back to Gutenberg, and every block keeps rendering — nothing is locked inside a builder’s data format.
Use Cases
- Legal disclaimers — place your disclaimer on every product page and update it once when your terms change.
- Calls to action — maintain consistent CTAs across landing pages, blog posts, and sidebar widgets.
- Contact information — embed
{{blocks:phone}}and{{blocks:address}}everywhere. When you move offices, update one field. - Promotions — run a site-wide announcement with a countdown banner, and pair it with a scroll-triggered popup.
- Support notices — display maintenance windows, holiday hours, or service alerts across your site.
- Reusable form embeds — wrap a Contact Form 7 shortcode inside a block so you can swap forms site-wide from one place.
- Multi-site consistency — export your block library and variables, and import them on every site you run.
Blocks vs WordPress Patterns
WordPress introduced “Reusable Blocks” (now called “Synced Patterns”) in the Gutenberg block editor. However, the Blocks plugin works differently and has distinct advantages in several scenarios:
| Feature | Blocks Plugin | WordPress Patterns |
|---|---|---|
| Works in Classic Editor | Yes | No |
| Works in widgets | Yes (shortcode) | Limited |
| Works in theme files | Yes (do_shortcode) | No |
| Works in page builders | Yes (11 integrations) | No |
| Update once, update everywhere | Yes | Synced patterns only |
| Site variables ({{tokens}}) | Yes | No |
| Visibility conditions | Yes (login state, admin) | No |
| Export / import between sites | Yes (one JSON file) | Manual copy |
| Popup / banner display | Yes | No |
| Requires Gutenberg | No | Yes |
Specifically, if you use the Classic Editor, widget areas, a page builder, or need dynamic values inside your reusable content, the Blocks plugin is the more flexible option.
Common Questions
Can I use HTML in blocks?
Yes. The block editor supports full HTML. You can write any HTML, CSS, or JavaScript inside a block, and the content renders exactly as you wrote it.
Can I nest shortcodes inside a block?
Yes. You can place other plugin shortcodes inside a block — a Contact Form 7 form, a gallery, or any other plugin’s shortcode. WordPress processes nested shortcodes when the page renders.
What are site variables?
Variables are values you define once and reuse anywhere as a {{blocks:token}}. Write {{blocks:support_email}} inside any block, popup, or banner, and update the value in one place when it changes. Built-in tokens cover your contact details, social profiles, site identity, and dynamic dates like {{blocks:year}}.
Can I move my blocks to another site?
Yes. The Import / Export page downloads all blocks and variables as one JSON file and imports it on any other site running Blocks. Existing blocks are matched by title and never overwritten unless you choose to.
Does the plugin work with page builders?
Yes. Blocks ships dedicated integrations for Gutenberg, Elementor, Divi, Bricks, Beaver Builder, WPBakery, Oxygen, Breakdance, Thrive Architect, Zion Builder, and Fusion Builder — and any other builder that renders shortcodes works too.
Will the extra features slow my site down?
No. Block renders are cached, every optional feature is off by default and loads no code until enabled, and the performance toggles actively remove scripts you do not use. Blocks is built to make sites faster, not heavier.
How many blocks can I create?
There is no limit. Each block is stored as a custom post type in your WordPress database, and categories and tags keep large libraries organized.
Getting Started
The Blocks plugin gives you a simple way to manage reusable content, site-wide values, and everyday hardening across your WordPress site. Write once, paste everywhere, edit in one place.
Additionally, check out these other open source contributions and WordPress plugins:
- CF7 Mailchimp Extension — connect contact forms to Mailchimp.
- Quick Maps — embed Google Maps without an API key.
- Arc — VS Code Terminal Bridge for AI coding agents.
If you need help with the Blocks plugin or want to report an issue, contact us directly.
26.07.13.17
Reliable Live Chat and Cache-Safe Visitor State
Live chat now follows configured support hours and real operator availability, preserves existing provider identifiers, and recovers safely when Olark fails to appear. Visitor-specific initialization and geolocation responses are isolated from shared caches.
Improvements (4)
- Provider identifiers for Olark, Crisp, and Tawk are managed through validated Support settings; new installations default to empty values
- Existing provider identifiers migrate automatically so established sites keep working without reconfiguration
- Live chat reacts to support-hour transitions, operator availability, page focus, and resumed browser tabs without continuous polling
- Frontend asset URLs retain the exact plugin version so host and CDN caches invalidate predictably
Fixes (4)
- Visitor initialization and geolocation requests use unique request identifiers to prevent shared-cache responses from crossing visitors
- Olark visibility is confirmed after operators come online; failed rendering receives one session-throttled recovery reload
- Checkout, order-payment, and order-received pages are protected from live-chat recovery reloads
- Hidden tabs defer recovery until the visitor returns, avoiding background reloads
Patches (0)
26.07.12.13
Quality: Static Analysis Zero
A quality-focused release: the whole plugin now passes PHPStan level 9 with zero errors and Semgrep with zero findings, backed by a new regression test suite. No behavior changes intended.
Improvements (0)
Fixes (0)
Patches (0)
026.07.07.21
Honeypot Toggle Fix
Fixes the Anti-Spam honeypot toggles, which could not be enabled: checking the box saved nothing. Checkbox settings are standardized off-by-default across the plugin and the renderer now respects each registered default.
Improvements (0)
Fixes (0)
Patches (0)
026.07.07.15
GA4 Server-Side Ecommerce
Server-side GA4 ecommerce tracking arrives via the Measurement Protocol: purchase-funnel events fire from the server with no JavaScript added to the front end. Off by default and site-agnostic, with filters for consent gating and payload enrichment.
Improvements (0)
Fixes (0)
Patches (0)
026.07.05.18
License Campaigns for Specials
The Specials page gains a License Campaigns section: welcome-back and early-renewal discount percentages managed in one place. The public specials feed now publishes both values so storefront integrations can read a single source of truth.
Improvements (0)
Fixes (0)
Patches (0)
026.02.22.22
JS & CSS Performance + PHP 7.4 Fixes
Performance improvements for JavaScript and CSS loading. PHP 7.4 compatibility fixes and REST endpoint updates.
Improvements (2)
- JS & CSS performance improvements
- Updated REST API endpoints
Fixes (1)
- Fixed PHP 7.4 compatibility issues
Patches (0)
026.02.10.1904
Bug Fixes
Bug fixes for stability.
Improvements (0)
Fixes (1)
- Fixed various bugs reported after asset optimization update
Patches (0)
026.01.30.1153
Asset Optimization
Optimized assets with banner updates and UI improvements.
Improvements (3)
- Optimized JS and CSS asset loading
- Banner feature updates
- UI improvements
Fixes (0)
Patches (0)
026.01.26.01
Popup Feature
Added popup feature for block display.
Improvements (1)
- Added popup display option for blocks
Fixes (0)
Patches (0)
025.12.29.19
WordPress Coding Standards
Enhanced code quality with proper WordPress Coding Standards compliance.
Improvements (3)
- Full WordPress Coding Standards compliance
- Improved code quality and consistency
- Updated CSS styles
Fixes (0)
Patches (0)
025.12.02.02
Winter Cleaning
Bug fixes and code cleanup.
Improvements (0)
Fixes (1)
- Bug fixes and code cleanup
Patches (0)
25.11.05.1003
Bug Fixes & Improvements
Bug fixes and general improvements.
Improvements (1)
- General improvements to plugin functionality
Fixes (1)
- Fixed reported bugs and edge cases
Patches (0)
25.09.30.1006
Codebase Modernization
Modernized the codebase for better security and stability. New date-based versioning scheme.
Improvements (2)
- Modernized codebase with improved security patterns
- Migrated to date-based versioning scheme
Fixes (0)
Patches (1)
- Security hardening across core functions
1.6.55
Bug Fixes
Bug fixes and stability improvements.
Improvements (0)
Fixes (1)
- Fixed various bugs for improved stability
Patches (0)
1.6.42
Version Standardization
Tag versioning standardization in preparation for new release cycle.
Improvements (1)
- Standardized version tagging system
Fixes (0)
Patches (0)
1.6.23
TinyMCE Options
Added options for TinyMCE editor customization.
Improvements (1)
- Added TinyMCE configuration options for block editing
Fixes (0)
Patches (0)
1.6.21
Documentation Links
Updated documentation links throughout the plugin.
Improvements (1)
- Updated doc links to current URLs
Fixes (0)
Patches (0)
1.6.6
PHP Error Fixes
Corrected PHP errors for improved stability.
Improvements (0)
Fixes (1)
- Corrected PHP errors and warnings
Patches (0)
1.6.4
WordPress 4.8 Compatibility
Tested and verified compatibility with WordPress 4.8.
Improvements (1)
- Verified compatibility with WordPress 4.8
Fixes (0)
Patches (0)
1.6.3
jQuery Update
Updated jQuery implementation.
Improvements (0)
Fixes (1)
- Updated jQuery .on("load") event handler for compatibility
Patches (0)
1.6.2
Bug Fixes
Fixed bugs in block management.
Improvements (0)
Fixes (1)
- Fixed bugs in block content handling
Patches (0)
1.6.1
Admin Menu Update
Updated admin menu registration.
Improvements (1)
- Updated add_menu_page implementation
Fixes (0)
Patches (0)
0.3
WPautop Control
Added option to enable or disable WordPress automatic paragraph formatting.
Improvements (1)
- Added options to enable/disable WPautop per block
Fixes (0)
Patches (0)
0.0.21
HTML & CSS Options
Added HTML and CSS editing options for block content.
Improvements (2)
- Added HTML editing option for blocks
- Added CSS editing option for blocks
Fixes (0)
Patches (0)
0.0.19
Documentation Update
Further documentation improvements.
Improvements (1)
- Improved documentation and help text
Fixes (0)
Patches (0)
0.0.9
Documentation Update
Updated plugin documentation.
Improvements (1)
- Updated plugin documentation and usage instructions
Fixes (0)
Patches (0)
0.0.8
Editor Support
Added visual editor for block content.
Improvements (1)
- Added visual editor for block content creation
Fixes (0)
Patches (0)
0.0.6
Initial Release
First public release of Blocks on WordPress.org. Simple reusable content blocks with shortcode support.
Improvements (2)
- Reusable content blocks with shortcode generation
- Simple block management from WordPress admin