Article

How to Add a Waitlist to Ghost (Code Injection)

Add a GetWaitly waitlist to Ghost via Code Injection and an HTML card — site-wide or per-post. Includes the popup variant and fixes.

AAymane E.October 4, 20266 min read
Share
A laptop showing a Ghost blog being edited, representing adding a waitlist signup form

Ghost is a publishing platform, so a waitlist fits naturally: collect early readers before launch, then email them when the product or publication goes live. Ghost even has membership built in — but that is for paying subscribers of your content, not a pre-launch waitlist with referrals and broadcasts.

GetWaitly's widget drops into Ghost with two lines of code, and Ghost's Code Injection makes it easy. Here is the setup.

The short answer

Add the script to Settings → Code Injection → Site Footer, then put the container div where you want the form using an HTML card in a post or page. Ghost also supports per-post code injection. Total time: 5 minutes.

What you need

  • A GetWaitly account with a waitlist created (free plan covers 100 subscribers).
  • Your waitlist's public ID from the Widget/Embed section of the dashboard.
  • A Ghost site. Code Injection and the HTML card are available without editing your theme, on Ghost(Pro) and self-hosted Ghost.

Step 1 — Get your embed code

In GetWaitly, open the waitlist and go to Widget. Copy:

Script tag:

<script src="https://getwaitly.com/widget.js" defer></script>

Container div:

<div class="gw-widget" data-waitlist-id="YOUR_WAITLIST_ID"></div>

Use the waitlist's public ID, not the URL slug.

Step 2 — Load the script site-wide

  1. In Ghost admin, go to Settings → Code Injection (under Advanced on newer versions).
  2. Find the Site Footer box.
  3. Paste the script tag:
<script src="https://getwaitly.com/widget.js" defer></script>
  1. Save.

The Site Footer code is injected before the closing </body> on every page, so the widget is available everywhere without touching your theme.

Step 3 — Add the form to a page or post

Ghost's editor supports raw HTML through an HTML card:

  1. Edit the page or post where the waitlist belongs.
  2. Type /html and press Enter (or click + and choose HTML).
  3. Paste the container div:
<div class="gw-widget" data-waitlist-id="YOUR_WAITLIST_ID"></div>
  1. Preview or publish. The form renders where the card sits, styled with your waitlist branding.

Because the script is loaded site-wide in Step 2, the card only needs the div.

Alternative — per-post code injection

If you only want the script on one post, use Ghost's post-level Code Injection instead of the site-wide footer:

  1. Open the post and click the settings icon (top right).
  2. Expand Code Injection.
  3. Paste the script into Post Footer, and add the div with an HTML card in the body.

This keeps the script off every other page.

Step 4 — The popup variant (optional)

With the script loaded site-wide, add a trigger button with an HTML card:

<button class="gw-trigger" data-waitlist-id="YOUR_WAITLIST_ID">Join waitlist</button>

Clicking it opens the form in a modal — useful in a welcome post or a call-to-action box.

Step 5 — Test it

Ghost renders HTML cards and Code Injection on the published site (and usually in preview). Open the live page, submit a test email, and confirm the subscriber appears in your GetWaitly dashboard.

Ghost-specific notes

  • Code Injection is not theme editing. Your code survives theme changes because it lives in settings, not theme files. Prefer it over editing a theme's .hbs files.
  • HTML card vs Markdown card. A Markdown card may escape raw HTML. Use the HTML card for the container div.
  • Ghost members vs a waitlist. Ghost's members feature manages signups for your publication. GetWaitly is for pre-launch product interest with referral links and broadcast emails. They can coexist.
  • Do not load the script twice. If it is in the Site Footer and again in a post, remove one.

Alternative: the hosted page

If you would rather not touch code, publish GetWaitly's hosted page at getwaitly.com/w/your-id and link to it from a Ghost post or your navigation. The signup happens on GetWaitly's page. You can also embed it with Ghost's native /embed card using the hosted page URL.

FAQ

Does GetWaitly work on Ghost?

Yes. Load the widget script via Settings → Code Injection (Site Footer), then add the container div with an HTML card. Ghost injects the code on every page without theme edits.

Do I need a paid Ghost plan?

Code Injection and the HTML card are core Ghost features, available on Ghost(Pro) plans and self-hosted Ghost. GetWaitly is free to start (100 subscribers) with paid plans from $5/mo.

Why is my Ghost HTML card not rendering the form?

Check that the site-wide script is saved in Code Injection → Site Footer, that you used an HTML card (not Markdown), and that the data-waitlist-id matches your waitlist exactly.

Can I add a waitlist to just one Ghost post?

Yes. Use the post's Code Injection → Post Footer for the script and an HTML card for the div. This keeps the widget off other pages.

Should I use Ghost members or GetWaitly?

They solve different problems. Ghost members are for subscribing to your publication. GetWaitly is a pre-launch waitlist with referral tracking, queue positions, and broadcast emails. Use Ghost members for content, GetWaitly for launch interest.

Related guides

The simple, affordable waitlist for indie hackers. Start free in 5 minutes — no credit card required. Try GetWaitly free →

Aymane E.

Written by

Aymane E.

Founder of GetWaitly. I write about validating ideas, pre-launch, and growth from building a waitlist tool as a solo founder.

Follow on X →

Build your waitlist in 5 minutes

GetWaitly handles signups, referrals, broadcast emails, and analytics — free to start.