Free and Pro workflow guide
Place the right flag, in the right format, without maintaining SVG files by hand.
Choose from 271 verified country, territory, regional, and organisation flags, publish one flag or a responsive collection, and build linked, searchable or curated navigation when the project needs it. This guide covers SVG Flags Free and Pro 0.11.1.
Quick start
Add an accessible flag image
- Install and activate either SVG Flags Free or SVG Flags Pro—not both editions together.
- Edit a post or Page and insert the SVG Flag Image block.
- Choose a country, territory, region, or organisation in the searchable selector.
- Set the width and unit; enable the square option only when the 1:1 artwork suits the layout.
- Enable the country-name caption when visible identification helps the reader.
- Preview the published Page and confirm the image alternative text names the selected flag.
Checkpoint: use SVG Flag Image when the flag carries meaning. Its img output uses the catalogue country name as alternative text; the decorative Pro heading image intentionally uses an empty alternative.
Choose the output that matches the job
CSS-backed flag symbol for compact inline or block-level presentation. Use it when the adjacent text already supplies the meaning.
Lazy-loaded image with country-name alternative text, optional caption, and Pro border or spacing controls.
Responsive multi-flag gallery with ordered selection, favourite/recent shortcuts, one to eight columns and optional names.
Semantic H1–H6 containing a decorative flag before plain heading text.
A complete linked card with flag, title, description, destination and brand-ready presentation.
A complete or curated catalogue with search, region and A–Z filters, progressive loading and responsive cards.
The generated complete reference records every active block and shortcode attribute, default, accepted value and edition boundary. The heading block also retains saved compatibility attributes that its current renderer does not consume; the generated reference labels them explicitly instead of implying an active effect.


Use the bundled catalogue, not an assumed country list
Version 0.11.1 contains exactly 271 unique codes from the current flag-icons 7.5.0 library. Every code has both 4:3 and 1:1 SVG artwork. The catalogue includes current countries plus supported territories, regions, and organisations; the editor shows the label and code together so similar names can be distinguished.
- Shortcodes accept lower- or uppercase codes and normalize them against the catalogue.
- An invalid single-flag code falls back through the renderer’s normalization path instead of constructing an arbitrary asset URL.
- The grid removes invalid and duplicate codes and caps output at 100 items.
- Enabling Random selects one supported catalogue entry during each server-side render.
Build a responsive multi-country grid

The grid renderer produces one figure per valid code. With captions enabled, each figure displays the catalogue name and its image also carries that name as alternative text. The grid settings accept the units px, em, rem, %, and vw; use a constrained width and fewer columns when labels are long.
Build a searchable or curated directory in Pro
Use the complete catalogue, choose regions, or include an explicit ordered list of flags. You can remove exceptions, sort by country name or code, preserve the custom include order, choose an initial region and add visitor search, region and A–Z controls. Progressive loading keeps a large directory approachable while retaining an accurate result count.
- Use Included flags for a focused list and Excluded flags for exceptions to a wider regional directory.
- Use Included flag order when a campaign or commercial priority should determine the sequence.
- Set the batch size from 8 to 100 when Load more is enabled.
- Customise the no-results message and card background, text, border, hover state, corners and padding to match the site.
Know the Free and Pro boundary
| Capability | Free | Pro |
|---|---|---|
| Flag catalogue | All 271 flags in 4:3 and 1:1 artwork. | Includes the Free catalogue. |
| Blocks | SVG Flag, SVG Flag Image and SVG Flag Grid. | Adds SVG Flag Heading, Linked Flag Card and Searchable Flag Directory. |
| Editor speed | Favourite/recent shortcuts and ordered grid selection. | Uses the same faster picker across Pro curation controls. |
| Collections | Responsive galleries with captions and local SVG assets. | Adds per-flag links and captions, visitor search, region filtering, responsive breakpoints and cards. |
| Directories | — | Complete or curated lists, exclusions, stable ordering, initial region, A–Z, progressive loading and branded cards. |
| Single-flag presentation | Country selection, size, aspect ratio, caption, inline alignment and random selection where supported. | Adds linked cards, headings, element identity, custom tooltips/captions, borders and spacing. |
Settings are starting defaults: SVG Flags copies them into newly inserted blocks and Home starter drafts. Saving or resetting Settings does not rewrite existing content or alter explicit shortcode attributes.
Use shortcodes for established or code-led layouts
The active shortcode surfaces are [svg-flag], [svg-flag-image], [svg-flag-grid], and Pro [svg-flag-heading], [svg-flag-card] and [svg-flag-directory]. The older [svg-flags] alias still routes to [svg-flag].
[svg-flag flag="gb" size="1.25" size_unit="em" inline="true"] [svg-flag-image flag="ca" size="12" size_unit="rem" caption="true"] [svg-flag-grid flags="gb,us,ca,fr,de,jp" columns="3" gap="1" gap_unit="rem"] [svg-flag-heading flag="de" heading="Regional results" heading_tag="h2"] [svg-flag-card flag="gb" title="United Kingdom" description="Meet our UK team" url="/united-kingdom/"] [svg-flag-directory include_flags="gb,ie,fr,de,nl,es,it" sort_order="include_order" show_search="true" show_alphabet_nav="true"]
Shortcode booleans accept values interpreted by the plugin’s truthy conversion. Prefer the exact text true or false. The complete reference gives every released attribute, default, edition, accepted value, alias, and all 25 active PHP filters.
Treat flags as supporting information, not a language selector by themselves
A national flag does not uniquely identify a language, locale, currency, or audience. Pair it with a visible text label and a correctly declared link destination. Use SVG Flag Image or a captioned grid when the identity must be announced; use the CSS-backed symbol only when adjacent text already supplies an equivalent name.
- Do not rely on colour or flag shape alone to communicate a choice.
- Keep link or button semantics on the surrounding interactive element; SVG Flags itself renders the visual flag.
- Check country-name captions at narrow widths and avoid grids whose columns force labels to overlap.
- The Pro heading flag is decorative because the same heading contains the meaningful text.
Troubleshoot the selected surface first
The expected flag does not appear
Re-select the entry in the editor or verify the shortcode code against the searchable catalogue. The grid silently removes invalid entries; a copied label is not a substitute for the code.
A caption is missing
Confirm caption is enabled and the flag is not rendered inline. Single inline flags intentionally suppress the block caption; place a visible text label beside the flag instead.
The grid has fewer items than supplied
Duplicate and invalid codes are removed after filtering, and only the first 100 supplied values are considered. Check the normalized code list and remove unsupported values.
A Pro heading compatibility field has no visible effect
The current heading renderer consumes flag, size, size unit, square aspect, vertical alignment, random selection, heading text, and heading level. Other saved heading attributes remain registered for compatibility and are marked as such in the complete reference.
Include this context with a support request
- SVG Flags version and Free or Pro edition.
- WordPress, PHP, active theme, and editor or page-builder versions.
- The exact block or shortcode and an anonymised attribute example.
- The selected flag code, aspect ratio, size, and unit.
- A screenshot of the block controls and published result when relevant.
Still stuck?
Choose support for your edition.
Pro customers can sign in for private support connected to their purchase. Free-edition questions belong in the public WordPress.org support forum.