Custom Meta Tags
Per-page custom HTML via seoneo_custom and global field-to-tag mappings in module config — when to use each, and how values are escaped.
Two ways to add custom tags
SEO NEO handles the standard head output (title, description, canonical, Open Graph, Twitter, hreflang, robots, JSON-LD). When you need something outside that set, there are two mechanisms:
- Per-page custom HTML (
seoneo_custom) — paste raw markup for one page only. Rendered verbatim. - Global field-to-tag mappings — map any PW field on a template to a meta tag site-wide. Values are escaped before insertion.
Search-engine verification tags (Google, Bing, Yandex, and others) have dedicated module-config fields — use those rather than custom mappings when possible. See Configuration.
Per-page custom HTML (seoneo_custom)
Every page with the SEO tab has a Custom <head> HTML field (seoneo_custom). Editors paste arbitrary markup that SEO NEO drops into the page's <head> block.
Typical uses:
- Site-verification snippets for a single page or subdomain variant
- One-off
<meta>,<link rel="preload">, or<script type="application/ld+json">tags for a specific page - Campaign-specific tags (e.g. a custom
theme-coloron a landing page)
The field content is rendered verbatim — SEO NEO does not escape it, because the whole point is to let you paste raw HTML. Restrict edit access to trusted roles. The field is created with tags=SeoNeo so you can target it in field-permissions UI.
For editor-facing detail, see The SEO Tab.
Global field-to-tag mappings
In Modules > Configure > SeoNeo > Custom tag mappings, map any PW field to any meta tag. One rule per line, in the format fieldname=<tag template with %s>:
seoneo_keywords=<meta name="keywords" content="%s">
seoneo_og_type=<meta property="og:type" content="%s">
fb_app_id=<meta property="fb:app_id" content="%s">
The field value replaces %s. Empty fields are skipped. The value is escaped before insertion (unlike seoneo_custom).
Use mappings when the same field should emit the same tag shape on every page where that field has a value. Use seoneo_custom for one-off markup that does not map cleanly to a single field.
When to use which
| Scenario | Use |
|---|---|
| Google Search Console verification on the homepage | Module config verification fields (not custom HTML) |
| Per-page JSON-LD for a niche schema type | seoneo_custom or a getJsonLd hook |
Emit og:type from seoneo_og_type on every page | Built-in resolver (preferred) or a global mapping |
| Legacy field that must become a meta tag during migration | Global mapping, then remove once fields are renamed |
| Raw HTML paste from a third-party dashboard | seoneo_custom |
See also
- The SEO Tab — where editors find the
seoneo_customfield. - Configuration — verification tags, author meta, and the custom tag mappings fieldset.
- Structured Data (JSON-LD) — built-in
@graphoutput and hooks for extending it.
Last updated