Evenings.fmEvenings Docs

Guides

How to embed the SMS signup form on your website

Updated

Listeners can already subscribe to SMS alerts from your station page on Evenings. With the embed, the same form lives on your own website: a visitor enters their number, confirms a one-time code, and gets a text when you have updates.

Get your embed code

  1. Open your station's Account page.
  2. Find the SMS Signup Embed panel near the bottom of the page, just above Appearance.
  3. Pick a style (Minimal or Card), and whether your site's background is light or dark. Optionally set colours, corner radius, font and your own text. The preview updates as you type.
  4. Click Copy and paste the code into your site wherever custom HTML is allowed.

The simplest snippet looks like this:

<div data-evenings-sms="your-station"></div>
<script async src="https://evenings.fm/embed/sms.js"></script>

The script replaces the div with the form and keeps its height in sync, so it never scrolls or gets clipped. You can place several forms on one page; the script picks up every data-evenings-sms element.

Two styles

  • Minimal (the default) is just the country code, the phone field and a button on a transparent background, with one line of helper text underneath. No panel, no padding, no heading unless you add one. It is meant to sit inside your own layout and take on your colours.
  • Card (data-style="card") is a padded, rounded panel with a heading, like the form on your Evenings station page.

The button always sits under the phone field, and both styles end with a small "Powered by Evenings.fm" line that cannot be hidden. "Evenings.fm" links to the Evenings website and opens in a new tab.

Both come in a light theme (dark text, for light pages; the default) and a dark theme (light text, for dark pages). Because the minimal style is transparent, set data-theme="dark" if your page background is dark, or the text will not be visible.

Iframe-only version

Some site builders strip <script> tags from custom HTML blocks. Switch the panel to Iframe only and paste that instead:

<iframe src="https://evenings.fm/embed/your-station/sms"
  title="Subscribe via SMS" width="100%" height="190"
  style="border:0;max-width:420px;display:block" loading="lazy"></iframe>

This version has a fixed height, so adjust height if your text wraps to more lines.

Customization options

Every option can be set as a data-* attribute on the div (script version) or as a query parameter on the iframe URL. Anything invalid is ignored and the default is used.

Structure

OptionValuesDefault
styleminimal, cardminimal
themelight (dark text), dark (light text)light
alignleft, centerleft
hideComma-separated parts to leave out: heading, descriptionNothing hidden
width(script only) Max width of the form, e.g. 100% or 360px420px

Colours

OptionValuesDefault
accentHex colour for the button, e.g. #ff3b30Near-black (light) / white (dark)
button-textHex colour for the button labelBlack or white, whichever reads better on accent
textHex colour for textNear-black (light) / white (dark)
bgHex colour or transparent for the backgroundtransparent (minimal) / white or #171717 (card)
input-bgHex colour or transparent for the fieldstransparent (minimal) / a faint tint of text (card)
borderHex colour or transparent for the field bordersA tint of text

Shape and type

OptionValuesDefault
input-radiusCorner radius of the fields in pixels, 0–9996 (minimal) / 12 (card)
button-radiusCorner radius of the button in pixels, 0–9996 (minimal) / 999 (card)
radiusCorner radius of the background panel in pixels, 0–480 (minimal) / 24 (card)
paddingSpace around the form in pixels, 0–640 (minimal) / 28 (card)
sizeBase font size in pixels, 12–20. Everything scales with it.14 (minimal) / 15 (card)
fontA CSS font-family that is installed on the visitor's device, e.g. Georgia, serifThe visitor's system font

Text

OptionValuesDefault
headingYour own heading, up to 80 charactersNone (minimal) / "Get notified when Station has updates" (card)
descriptionYour own helper text, up to 200 characters"Get text updates. Reply S to stop."
buttonLabel for the first button, up to 30 characters"Verify Number"

Examples

Square corners and your brand colour, for a light page:

<div data-evenings-sms="your-station"
  data-accent="#0035ff"
  data-input-radius="0" data-button-radius="0"
  data-button="Text me"></div>
<script async src="https://evenings.fm/embed/sms.js"></script>

The fields and button without the helper text, on a dark page:

<div data-evenings-sms="your-station"
  data-theme="dark" data-hide="description"></div>
<script async src="https://evenings.fm/embed/sms.js"></script>

If you hide the helper text, say somewhere near the form what people are signing up for (a text when you have updates, at most once a day, reply S to stop).

The card from your station page:

<div data-evenings-sms="your-station" data-style="card" data-theme="dark"></div>
<script async src="https://evenings.fm/embed/sms.js"></script>

How subscribers are handled

Signups from the embed are the same as signups from your station page: they appear in your Subscribers count, receive the same "went live" texts, and can reply S at any time to unsubscribe. Verification codes are sent by SMS and each number is limited to a few attempts per 15 minutes to prevent abuse.

Platform notes

  • Squarespace, Webflow, Wix, WordPress: use a Code / Embed / Custom HTML block and paste the script version.
  • Framer: add an Embed component set to HTML and paste the script version.
  • Notion, Carrd and others that block scripts: use the iframe-only version.