ZeeMee Polylang Block Visibility – Free WordPress plugin for language control on blocks

ZeeMee Polylang Block Visibility makes it easy to control the visibility of Gutenberg blocks based on the active language of your website.

The plugin adds a simple language control panel to every block in the WordPress block editor. This allows editors to specify one or more HTML language codes (for example da, en, or en-US). The block will then only be displayed when the current page language matches the specified language codes.

This feature is particularly useful on multilingual websites where certain blocks should only appear in specific languages.

Key Features

  • Adds a language visibility control to all Gutenberg blocks
  • Supports multiple language codes per block
  • Works seamlessly with Polylang
  • Automatically falls back to the site’s WordPress locale if Polylang is not active
  • No impact on the editor experience or site performance
  • Lightweight and developer-friendly implementation

How It Works

When editing a block in the Gutenberg editor, a new panel called “Language Control (HTML Lang)” appears in the block inspector. Here you can enter one or more language codes separated by commas.

Examples:

  • da → show only on Danish pages
  • en → show only on English pages
  • da,en → show on both Danish and English pages

If the field is left empty, the block will appear on all languages, which preserves the default WordPress behavior.

On the frontend, the plugin checks the current language (via Polylang if available, otherwise via the WordPress locale) and automatically hides blocks that do not match the defined language codes.

Use Cases

  • Multilingual marketing pages
  • Language-specific call-to-action blocks
  • Different legal text per language
  • Region-specific notices
  • Conditional multilingual content inside the same page layout

Compatibility

  • WordPress Block Editor (Gutenberg)
  • Polylang
  • All standard and custom blocks