Custom code

Add analytics, verification tags and widgets to your public site by pasting HTML into the header or footer.

Under Website → Settings → Custom code you can add snippets that run on every page of your public site exactly as pasted.

Two slots

Slot Rendered Use for
Header scripts & tags Just before </head> Site-verification meta tags, analytics that must load early.
Footer scripts Just before </body>, after your content Chat widgets and non-critical tags; anything that should not slow the first paint.

Each slot holds up to 10,000 characters.

Rules

  • Snippets must not contain <html>, <head>, <body> or <base> tags, and every <script> must be closed.
  • Code runs on your site only: never on mezaic.co or in the portal.
  • Blocking scripts in the header slow every page for every visitor; prefer async/defer or the footer slot.

Examples

Verify a site with Google Search Console (header):

HTML
<meta name="google-site-verification" content="your-token">

Add a privacy-friendly analytics script (footer):

HTML
<script defer data-domain="yourname.com" src="https://plausible.io/js/script.js"></script>

Do you need this for analytics?

Mezaic already includes Analytics with views, visitors, referrers, countries and link clicks, without cookies. Add third-party analytics only if you need something it does not offer.