Sample guide. Made automatically by our Idea to Finished Product engine in about 8 minutes. BackGet my guide

The 90 Day Alcohol-Free Guide

A phone app that buyers add to their home screen: they fill in their why and game plan, download it as a PDF, then mark drink or no drink every day for 90 days after a daily reminder.

Sample custom build guide, made by Saha Synergy from a real creator's answers. Her name is removed.

Your why
Why am I doing 90 days alcohol-free?

Question 1 of 10

Your answers are saved on this phone only.

You can change them any time.

Next
Today
Day 12 of 90

Did you drink today?

Week 2: The Dip

Focus: lean on people, don't isolate.

No drink today
Week check-in
End of week 1

What did I overcome this week and what got me through it?

What surprised me most this week?

Save my check-in
Day 90
Made it to 90

Well done.

Your plan, tracker and check-ins are ready as a PDF.

Come find me @yourhandle

Download my PDF

Mock-up of the finished product.

1. The flow

What your customer does, start to finish

The count is no-drink days out of 90, so one drink day does not reset the count to zero.

2. Content edits

Fix the content first, then build

Replace the cursive font

Your friend found the cursive hard to read. Use a plain sans-serif font for all questions, tips and buttons in the app and the PDF. Keep cursive for your name on the cover only, if you want it at all.

Reword question 7

Change it to: 'When I'm out, what non-alcoholic drink will I order instead?'

Remove the January and 31-day wording

Question 1 becomes 'Why am I doing 90 days alcohol-free?'. Question 2 becomes 'What's one thing I want to prove to myself in these 90 days?'. Question 3 becomes 'How am I going to feel once I've completed 90 days?'. The week 4 rotating question 'What do I want to keep doing in February?' becomes 'What do I want to keep doing after day 31?'. 'Made it to 31' becomes a day 31 milestone, and the new ending is 'Made it to 90'.

Change the tick box to drink or no drink

Your guide asks people to tick each alcohol-free day. The app asks every day: drink or no drink. Write one short line for drink days (a suggestion for you to write), in your voice, with no shame, plus a reminder to text the person they named in question 5.

Keep the disclaimer as the first screen

Keep your exact wording: based on your personal experience, not medical advice, and anyone physically dependent on alcohol should seek professional help. Buyers tick 'I have read this' before they reach the questions. Repeat it in the PDF footer. Do not add any health claims of your own beyond your experience.

Frame the week by week notes as your experience

Lines such as 'sleep gets better fast' and 'skin starts to clear' read as promises. Retitle the section 'What I noticed' or add 'in my experience' to each week, so the notes match your disclaimer.

Explain the three hard-day ideas

'Most of the fear isn't your own' is unclear on its own. Add one sentence under each of the three ideas explaining what you mean. This is a suggestion for you to write.

Write weeks 5 to 13

Your guide covers weeks 1 to 4. A 90-day version needs 9 more weeks: a name, what you noticed, a focus and a rotating check-in question for each. You write these from your own experience.

Update the free guide's last page

Under 'Well done / Made it to 31', add one line and a link to the 90-day version. This is the main route from the free guide to the paid product.

Content plan

How your guide maps into the app. Rows marked 'Suggestion: you write' are new content only you can write.

PartDaysFrom your guideGoes intoStatus
DisclaimerBefore day 1Your disclaimer textFirst screen with a required tick box, and the PDF footerReady
WelcomeBefore day 1WELCOME. I'm the creator... (edited for 90 days)Welcome screenEdit the 31-day wording
Your whySetupQuestions 1 to 5Questionnaire, one question per screen, and the PDFEdit questions 1 to 3
Your game planSetupQuestions 6 to 10Questionnaire and the PDFEdit question 7
TrackerDays 1 to 9031-day tick boxes, 'My reason', 'The person I've told'Today screen and a 90-day calendar. Answers to questions 1 and 4 shown on Today.Ready
When it gets hardAny dayThree ideas plus 'text the person you named'A 'When it gets hard' screen, linked from Today and from drink daysSuggestion: you write one sentence per idea
Three lines for the barAny dayThe three bar linesSame screen as 'When it gets hard'Ready
Week 1: The Adjustment1 to 7Expect, focus: rest, 'What surprised me most this week?'Week tip on day 1, check-in on day 7Ready
Week 2: The Dip8 to 14Expect, focus: lean on people, 'What am I most looking forward to?'Week tip on day 8, check-in on day 14Ready
Week 3: The Shift15 to 21Expect, focus: replacement ritual, Saturday morning questionWeek tip on day 15, check-in on day 21Ready
Week 4: The Glow Up22 to 28Expect, focus: reread your whyWeek tip on day 22, check-in on day 28Edit the February question
Weeks 5 to 829 to 56Nothing yetWeek tips and check-insSuggestion: you write. Topic idea: what changed for you after day 31.
Weeks 9 to 1257 to 84Nothing yetWeek tips and check-insSuggestion: you write. Topic idea: what you did when the novelty wore off.
Week 1385 to 90Nothing yetWeek tip on day 85, final check-in on day 90Suggestion: you write
Weekly check-inDays 7, 14, 21 and so onThree fixed questionsCheck-in screen every week, saved into the PDFReady
Drink day messageAny drink dayNothing yetShown after a buyer marks 'I drank'Suggestion: you write
Day 31 milestone31Well done / Made it to 31Milestone screenSuggestion: you write one new line about the next 59 days
Day 90 ending90Nothing yetCelebration screen and PDF last page, with @yourhandleSuggestion: you write
Reminder textDailyNothing yetPhone notificationSuggestion: you write, 12 words or fewer

You write

3. Accounts

Every account you need

ToolJobCost
Claude (Claude Code)Writes and edits all the code from your promptsCheck current pricing
GitHubStores the project files so Vercel can publish themCheck current pricing
VercelHosts the app and runs the /api functionsHobby plan is free. Research note (unconfirmed): Hobby is meant for personal, non-commercial use, and Pro is about $20/month per user. Check current pricing and terms.
SupabaseStores one small table of reminder subscriptionsFree plan. Research note (unconfirmed): 2 active projects, 500 MB database. Check current pricing.
cron-job.orgCalls the reminder function once an hourCheck current pricing
Lemon Squeezy (recommended)Takes payment and delivers the access card PDFAbout 5% + 50¢ per sale, handles sales tax and VAT (unconfirmed, check current pricing). Alternatives: Gumroad about 10% + 50¢ and handles sales tax; Stripe about 2.9% + 30¢ (US cards) or 1.5% + 20p (standard UK cards) with no monthly fee.
CanvaYou edit your free guide and design the access card PDFCheck current pricing

Vercel's free Hobby plan is meant for personal, non-commercial use according to the research notes (unconfirmed). You are selling this product, so read Vercel's Hobby terms at vercel.com/docs/plans/hobby before launch. If paid use needs Pro (about $20/month per user, unconfirmed), budget for it. The app is built with no server-side user accounts, so moving hosts later is a copy of the same files.

4. How it works

Answers stay on the phone. The server stores only reminder times.

Where the data lives

Answers, daily marks and check-ins are saved in the browser storage on the buyer's phone. The PDF is created on the phone with jsPDF. Nothing personal is sent to a server.

What the server stores

One Supabase table: the phone's push address and keys, the reminder hour, the time zone and the date of the last reminder. No names, emails, answers or drink data.

The trade-off

If a buyer clears browser data or changes phone, their entries are gone. To cover this, the app offers a PDF download at any time and a backup file they can save and restore. The access code is shared by all buyers, so someone can pass it on. You can change the code in Vercel at any time.

iPhone reminders

Research note (unconfirmed, check webkit.org): web push on iPhone needs iOS or iPadOS 16.4 or later, works only after the buyer adds the site to the Home Screen, needs a web app manifest, and permission must be asked after a tap. This is why setup asks buyers to add the app to the Home Screen before answering questions or turning on reminders.

Supabase free projects pause

Research note (unconfirmed): free projects pause after about 1 week of inactivity. The hourly cron-job.org call reads the table every hour, which keeps the project active.

Vercel Hobby terms

Research note (unconfirmed): Hobby is meant for non-commercial use. Check before you sell.

The loop

5. Build steps

Follow these in order

  1. Fix your contentMake the edits in 'Content edits' above. Change the font, reword question 7 and remove the January wording. Update the last page of your free guide with a link placeholder.
  2. Write the new contentWrite weeks 5 to 13, the drink day message, the day 31 and day 90 messages and the reminder text. Write them in a plain document first. Later you paste them into the content files that Claude Code creates.
  3. Create your accountsSign up for Claude, GitHub, Vercel, Supabase, cron-job.org and Lemon Squeezy. Use the same email for all of them. Save every password in a password manager.
  4. Set up Claude CodeInstall Claude Code using Anthropic's install guide. Make an empty folder called ninety-days on your computer. Open Claude Code in that folder.
  5. Add the starter files and the master promptAsk Claude Code: 'Create these files with exactly this content.' Then paste each file from the 'Files' section of this guide. Then paste the master prompt. Answer its questions. Let it finish every screen.
  6. Create the database tableIn Supabase, create a new project. Open SQL Editor, click New query, paste supabase/schema.sql and click Run. Open Project Settings, then API, and copy the project URL and the service role key. Never share the service role key.
  7. Make your keys and secretsAsk Claude Code: 'Run npx web-push generate-vapid-keys and show me the two keys.' Then ask it for a random 32-character CRON_SECRET. Choose an access code, for example NINETY2026. Keep all of them in your password manager, not in any file.
  8. Publish on VercelAsk Claude Code to put the project on GitHub. In Vercel, click Add New Project, pick the repository and choose Framework Preset: Other. Under Environment Variables, add every name from .env.example with your values. Click Deploy. Copy the app address, for example ninety-days.vercel.app.
  9. Turn on the hourly reminder jobIn cron-job.org, create a job with the URL https://YOUR-APP.vercel.app/api/send-reminders and schedule it every hour at minute 0. Add a request header named x-cron-secret with your CRON_SECRET as the value. Run it once and check that the response says checked, sent, removed and failed.
  10. Test on real phonesWork through the three test checklists below on your iPhone, an Android phone and a laptop. Use the hidden debug date setting to jump to days 7, 31 and 90. Fix anything that fails by describing the problem to Claude Code in plain words.
  11. Set up the checkoutDesign a one-page access card PDF in Canva: app link, access code and Home Screen steps. In Lemon Squeezy, create a product at your price and attach the access card as the download. Make one test purchase and refund it.
  12. Beta, then launchGive the access code to 5 to 10 women from your audience for one week. Ask them three things: what confused you, did the reminder arrive, did the PDF open. Fix those issues, then launch.
Master prompt for Claude Code (select all, copy, paste)
You are building a small installable web app (PWA) for me, the creator. Working name: The 90 Day Alcohol-Free Guide. Short name: 90 Days. I have never coded. Do all the work. Explain each step in plain words. Ask me before deleting anything.

WHAT IT IS
Women who finished Dry January buy it to keep going for 90 days. They fill in my why and game plan questions, download them as a PDF, add the app to their home screen, get a daily reminder and mark each day drink or no drink. Week tips appear at the start of each week. A check-in appears at the end of each week. A celebration appears on day 31 and day 90.

STACK (keep it this simple)
1. Static HTML, CSS and plain JavaScript in the project root: index.html, styles.css, app.js. No framework, no build step, no bundler.
2. Backend: Node serverless functions in /api as ES modules, hosted on Vercel.
3. Supabase stores only push subscriptions.
4. These files already exist: supabase/schema.sql, api/unlock.js, api/vapid-public-key.js, api/subscribe.js, api/unsubscribe.js, api/send-reminders.js, sw.js, manifest.json, package.json, .env.example, content/questions.json, content/weeks.json, content/tips.json. Read them first. Keep their behavior and their API contracts. Load all text in the app from the content JSON files, never hard-code my content in app.js.
5. PDF: download the jsPDF UMD build file jspdf.umd.min.js into /vendor and load it from there so it works offline. Do not load anything from a CDN.
6. Create icons/icon-192.png, icons/icon-512.png and icons/apple-touch-icon.png (180x180): a #E0338A square with white bold text '90'. I may replace them later.

LOOK
1. Brand colour #E0338A. Background #FFFFFF. Text #1F1A1D. Soft pink panels #FDEAF3.
2. Font: system sans-serif stack (-apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif). Body 18px, line height 1.5. No cursive or script fonts anywhere.
3. Primary buttons: #E0338A background, white bold text at 18px or larger. Any small pink text uses #B0216A so it passes WCAG AA contrast.
4. Tap targets at least 48px tall. Content max width 480px, centered. Rounded corners 16px. Plenty of white space. One main action per screen.
5. Respect prefers-reduced-motion. Support the phone's larger text setting.

DATA (all on the phone)
1. Store everything in localStorage under the key 'ninety.v1' as one JSON object: { unlocked: boolean, disclaimerAccepted: boolean, installedSeen: boolean, startDate: 'YYYY-MM-DD' or null, answers: { q1 to q10: string }, days: { 'YYYY-MM-DD': 'none' or 'drink' }, checkins: { '1': { a1, a2, a3, a4, savedAt } }, weekIntrosSeen: [numbers], milestonesSeen: { d31: boolean, d90: boolean }, reminder: { on: boolean, hour: number } }.
2. Save after every change. Answers autosave while typing.
3. All dates are local dates from the phone clock in YYYY-MM-DD, never UTC.
4. Day number = whole days between startDate and today, plus 1. Week number = ceil(day / 7). Week 13 is days 85 to 90.
5. Count shown everywhere: 'No-drink days: X'. Never show a streak that resets.

SCREENS (one page, hash routes, browser back button works)
1. Unlock: field for the access code, button 'Unlock'. POST /api/unlock with { code }. On success set unlocked true. Show the error message from the API on failure.
2. Disclaimer: text from tips.json 'disclaimer'. Checkbox 'I have read this'. Button 'Continue' disabled until ticked.
3. Welcome: text from tips.json 'welcome'. Button 'Let's start'.
4. Add to Home Screen: detect standalone mode (matchMedia display-mode standalone or navigator.standalone). If already installed, skip this screen. iPhone: show the steps Share button, Add to Home Screen, then open the app from the new icon and continue there. Android and desktop Chrome: show an 'Install app' button using beforeinstallprompt when available, otherwise show the browser menu steps. Buttons 'I have added it' and 'Skip for now'.
5. Questions: one question per screen from questions.json. Show the section title, 'Question 3 of 10', a large textarea, Back and Next. Answers are optional, but if empty show a gentle line 'You can come back to this.'
6. Review: all 10 answers grouped by section, each with an Edit link. Button 'Download my plan (PDF)'.
7. Reminder: hour picker (all 24 hours, shown as 8:00 pm style, default 8:00 pm). Button 'Turn on daily reminder'. Only after that tap: check support, call Notification.requestPermission, register sw.js, get the key from GET /api/vapid-public-key, subscribe with pushManager (userVisibleOnly true), then POST /api/subscribe with { subscription, hour, tz: Intl.DateTimeFormat().resolvedOptions().timeZone }. On iPhone when not in standalone mode, explain that reminders work only from the Home Screen app and link back to screen 4. If permission is denied, explain how to allow notifications in phone settings. Always offer 'Skip for now'. When leaving this screen, set startDate to today if it is empty, then go to Today.
8. Today: 'Day N of 90', the current week name and focus from weeks.json, 'No-drink days: X', the buyer's answer to q1 under 'My reason' and q4 under 'The person I've told'. Two big buttons: 'No drink today' and 'I drank today'. After 'No drink' show a short positive confirmation. After 'I drank' show tips.json 'drinkDay', the q5 answer as 'Text: [name]', and a link to When it gets hard. If yesterday is unmarked, show a small card 'You didn't mark yesterday' with the same two choices. Links: Calendar, When it gets hard, Settings. Before the first day after setup, Today shows Day 1.
9. Week tip popup: on the first open of day 1, 8, 15 and so on, show the week name, 'What I noticed' lines and the focus. Show each week once, recorded in weekIntrosSeen. It can be reopened from Calendar.
10. Weekly check-in popup: from day 7, 14, 21 and so on, after the day is marked or on the next open, show the three fixed questions from tips.json 'checkin' plus the week's rotating question from weeks.json. Buttons 'Save my check-in' and 'Later'. Week 13 check-in appears on day 90. Every check-in can be opened and edited from Calendar.
11. Calendar: 90 cells in rows of 7 with week labels. A no-drink cell is #E0338A with a white tick, a drink cell is a grey dot and an unmarked cell is outlined. Each cell has a text label for screen readers. Tap a past or today cell to choose No drink, Drink or Clear. Future cells are disabled.
12. When it gets hard: the three ideas with their explanations, the line about texting the person they named (insert the q5 answer), then the three bar lines from tips.json.
13. Day 31 milestone: shown once when day 31 is reached, text from tips.json 'day31'.
14. Day 90 celebration: shown once on day 90 after marking. 'Made it to 90', tips.json 'day90', 'No-drink days: X of 90', a CSS confetti effect that is skipped when reduced motion is on, the sign-off from tips.json and the button 'Download my PDF'. After day 90, Today shows a finished state with the same summary, the PDF button and 'Start another 90 days', which first offers the PDF, then asks for confirmation twice and keeps the answers but clears days, check-ins and milestones.
15. Settings: change the reminder time (POST /api/subscribe again), turn off the reminder (unsubscribe in the browser and POST /api/unsubscribe with { endpoint }), download the PDF, 'Save a backup file' (downloads the localStorage JSON as ninety-days-backup.json), 'Restore from backup' (file picker, validate the shape before saving), and 'Reset everything' with two confirmations. Show the disclaimer text at the bottom.

PDF (jsPDF, A4 portrait, built-in Helvetica, wrap all long text, add pages as needed)
1. Cover: title, 'by the creator', the buyer's start date.
2. Your why: questions 1 to 5 with answers.
3. Your game plan: questions 6 to 10 with answers.
4. Tracker: a 90-cell grid, ticks for no drink, a dot for drink, blank for unmarked, and the no-drink count.
5. Every saved weekly check-in with its questions.
6. The bar lines and the hard-day ideas.
7. Footer on every page: the disclaimer in small text. Last line: the sign-off from tips.json.
8. File name: my-90-days.pdf. On iPhone make sure the file opens in the share sheet or a new tab so it can be saved to Files.

PWA
1. Link manifest.json. Add theme-color #E0338A, apple-touch-icon and the apple-mobile-web-app-capable and apple-mobile-web-app-title meta tags.
2. Register sw.js on load. Offline, the app must open and work with saved data.
3. When a notification is tapped, sw.js either sends a message { type: 'mark-today' } to an open window or opens '/?mark=today'. In both cases app.js opens Today.

ACCESSIBILITY
Use real buttons and labels, visible focus outlines and a logical heading order. Popups trap focus and close with Escape. Never use colour alone to show meaning.

TESTING
1. Add a hidden debug mode: when the URL has ?debug=1, Settings shows a date field that overrides 'today'. I use it to check week tips, check-ins, day 31 and day 90 without waiting.
2. Explain how to run it locally with npx vercel dev, and tell me which environment variables I need.
3. Before you say you are done: check the console for errors, check the app installs from Chrome, check that it opens offline, and walk through every screen above on a 375px wide screen.
4. Finish with a short list of what I still need to do myself (accounts, keys, Vercel settings, cron-job.org).
6. Backend files

The backend, ready to paste

Starting files for Claude Code. Test each one before you launch.

supabase/schema.sql · Run once in Supabase: SQL Editor, New query, paste, Run. One table, no personal data.
-- Stores only what is needed to send one daily reminder.
create table if not exists public.push_subs (
  endpoint text primary key,
  p256dh text not null,
  auth text not null,
  remind_hour smallint not null check (remind_hour between 0 and 23),
  tz text not null,
  last_sent date,
  created_at timestamptz not null default now()
);

-- Row level security on with no policies:
-- the public anon key cannot read or write this table.
-- Only the /api functions, using the service role key, can reach it.
alter table public.push_subs enable row level security;

create index if not exists push_subs_hour_idx on public.push_subs (remind_hour);
api/unlock.js · Checks the access code from the access card. ACCESS_CODES can hold several codes separated by commas, so you can change the code without breaking old buyers.
import { timingSafeEqual } from 'node:crypto';

function same(a, b) {
  const x = Buffer.from(a);
  const y = Buffer.from(b);
  return x.length === y.length && timingSafeEqual(x, y);
}

export default function handler(req, res) {
  if (req.method !== 'POST') {
    return res.status(405).json({ error: 'Method not allowed' });
  }
  const raw = req.body && typeof req.body.code === 'string' ? req.body.code : '';
  const code = raw.trim().toUpperCase();
  if (code.length < 4 || code.length > 64 || !/^[A-Z0-9-]+$/.test(code)) {
    return res.status(400).json({ error: 'Enter the access code from your access card.' });
  }
  const valid = (process.env.ACCESS_CODES || '')
    .split(',')
    .map((c) => c.trim().toUpperCase())
    .filter(Boolean);
  if (valid.length === 0) {
    return res.status(500).json({ error: 'Server not configured' });
  }
  if (!valid.some((c) => same(c, code))) {
    return res.status(401).json({ error: 'That code does not match. Check your access card.' });
  }
  return res.status(200).json({ ok: true });
}
api/vapid-public-key.js · Gives the app the public push key. The public key is safe to share. The private key stays in Vercel.
export default function handler(req, res) {
  if (req.method !== 'GET') {
    return res.status(405).json({ error: 'Method not allowed' });
  }
  const key = process.env.VAPID_PUBLIC_KEY;
  if (!key || key.length > 200) {
    return res.status(500).json({ error: 'Server not configured' });
  }
  res.setHeader('Cache-Control', 'public, max-age=3600');
  return res.status(200).json({ key });
}
api/subscribe.js · Saves or updates one phone's reminder. Validates the push address, keys, hour and time zone.
import { createClient } from '@supabase/supabase-js';

const B64URL = /^[A-Za-z0-9_-]+={0,2}$/;

function validTimeZone(tz) {
  if (typeof tz !== 'string' || tz.length === 0 || tz.length > 64) return false;
  try {
    new Intl.DateTimeFormat('en-US', { timeZone: tz });
    return true;
  } catch {
    return false;
  }
}

export default async function handler(req, res) {
  if (req.method !== 'POST') {
    return res.status(405).json({ error: 'Method not allowed' });
  }
  const body = req.body || {};
  const sub = body.subscription || {};
  const keys = sub.keys || {};
  const hour = Number(body.hour);

  if (typeof sub.endpoint !== 'string' || sub.endpoint.length > 1000) {
    return res.status(400).json({ error: 'Invalid subscription' });
  }
  let url;
  try {
    url = new URL(sub.endpoint);
  } catch {
    return res.status(400).json({ error: 'Invalid subscription' });
  }
  if (url.protocol !== 'https:') {
    return res.status(400).json({ error: 'Invalid subscription' });
  }
  if (typeof keys.p256dh !== 'string' || keys.p256dh.length > 200 || !B64URL.test(keys.p256dh)) {
    return res.status(400).json({ error: 'Invalid subscription keys' });
  }
  if (typeof keys.auth !== 'string' || keys.auth.length > 100 || !B64URL.test(keys.auth)) {
    return res.status(400).json({ error: 'Invalid subscription keys' });
  }
  if (!Number.isInteger(hour) || hour < 0 || hour > 23) {
    return res.status(400).json({ error: 'Hour must be 0 to 23' });
  }
  if (!validTimeZone(body.tz)) {
    return res.status(400).json({ error: 'Invalid time zone' });
  }

  const supabase = createClient(process.env.SUPABASE_URL, process.env.SUPABASE_SERVICE_ROLE_KEY, {
    auth: { persistSession: false }
  });
  const { error } = await supabase.from('push_subs').upsert(
    {
      endpoint: sub.endpoint,
      p256dh: keys.p256dh,
      auth: keys.auth,
      remind_hour: hour,
      tz: body.tz
    },
    { onConflict: 'endpoint' }
  );
  if (error) {
    return res.status(500).json({ error: 'Could not save reminder' });
  }
  return res.status(200).json({ ok: true });
}
api/unsubscribe.js · Deletes one phone's reminder when the buyer turns reminders off.
import { createClient } from '@supabase/supabase-js';

export default async function handler(req, res) {
  if (req.method !== 'POST') {
    return res.status(405).json({ error: 'Method not allowed' });
  }
  const endpoint = req.body && req.body.endpoint;
  if (typeof endpoint !== 'string' || endpoint.length > 1000) {
    return res.status(400).json({ error: 'Invalid endpoint' });
  }
  try {
    if (new URL(endpoint).protocol !== 'https:') throw new Error('bad');
  } catch {
    return res.status(400).json({ error: 'Invalid endpoint' });
  }

  const supabase = createClient(process.env.SUPABASE_URL, process.env.SUPABASE_SERVICE_ROLE_KEY, {
    auth: { persistSession: false }
  });
  const { error } = await supabase.from('push_subs').delete().eq('endpoint', endpoint);
  if (error) {
    return res.status(500).json({ error: 'Could not remove reminder' });
  }
  return res.status(200).json({ ok: true });
}
api/send-reminders.js · cron-job.org calls this every hour with the x-cron-secret header. It sends one reminder per phone per local day, at the hour the buyer chose. Edit the title and body text to your own words.
import { createClient } from '@supabase/supabase-js';
import webpush from 'web-push';
import { timingSafeEqual } from 'node:crypto';

const PAYLOAD = JSON.stringify({
  title: 'Your 90 days',
  body: 'Drink or no drink today? Tap to mark it.',
  url: '/?mark=today'
});

function authorized(req) {
  const expected = Buffer.from(process.env.CRON_SECRET || '');
  const given = Buffer.from(String(req.headers['x-cron-secret'] || ''));
  if (expected.length < 16 || given.length !== expected.length) return false;
  return timingSafeEqual(given, expected);
}

function localParts(date, tz) {
  const parts = new Intl.DateTimeFormat('en-CA', {
    timeZone: tz,
    year: 'numeric',
    month: '2-digit',
    day: '2-digit',
    hour: '2-digit',
    hourCycle: 'h23'
  }).formatToParts(date);
  const get = (type) => parts.find((p) => p.type === type).value;
  return { day: `${get('year')}-${get('month')}-${get('day')}`, hour: Number(get('hour')) };
}

async function loadAll(supabase) {
  const rows = [];
  const size = 1000;
  for (let from = 0; ; from += size) {
    const { data, error } = await supabase
      .from('push_subs')
      .select('endpoint, p256dh, auth, remind_hour, tz, last_sent')
      .order('endpoint')
      .range(from, from + size - 1);
    if (error) throw error;
    rows.push(...data);
    if (data.length < size) return rows;
  }
}

export default async function handler(req, res) {
  if (req.method !== 'GET' && req.method !== 'POST') {
    return res.status(405).json({ error: 'Method not allowed' });
  }
  if (!authorized(req)) {
    return res.status(401).json({ error: 'Unauthorized' });
  }

  webpush.setVapidDetails(
    process.env.VAPID_SUBJECT,
    process.env.VAPID_PUBLIC_KEY,
    process.env.VAPID_PRIVATE_KEY
  );
  const supabase = createClient(process.env.SUPABASE_URL, process.env.SUPABASE_SERVICE_ROLE_KEY, {
    auth: { persistSession: false }
  });

  let rows;
  try {
    rows = await loadAll(supabase);
  } catch {
    return res.status(500).json({ error: 'Could not read subscriptions' });
  }

  const now = new Date();
  const due = [];
  for (const row of rows) {
    let local;
    try {
      local = localParts(now, row.tz);
    } catch {
      continue;
    }
    if (local.hour === row.remind_hour && row.last_sent !== local.day) {
      due.push({ row, day: local.day });
    }
  }

  let sent = 0;
  let removed = 0;
  let failed = 0;
  for (let i = 0; i < due.length; i += 50) {
    const batch = due.slice(i, i + 50);
    await Promise.all(
      batch.map(async ({ row, day }) => {
        const sub = { endpoint: row.endpoint, keys: { p256dh: row.p256dh, auth: row.auth } };
        try {
          await webpush.sendNotification(sub, PAYLOAD, { TTL: 3600 });
          await supabase.from('push_subs').update({ last_sent: day }).eq('endpoint', row.endpoint);
          sent += 1;
        } catch (err) {
          if (err && (err.statusCode === 404 || err.statusCode === 410)) {
            await supabase.from('push_subs').delete().eq('endpoint', row.endpoint);
            removed += 1;
          } else {
            failed += 1;
          }
        }
      })
    );
  }

  return res.status(200).json({ checked: rows.length, sent, removed, failed });
}
sw.js · Service worker: offline app shell, push notifications and notification taps. Change CACHE to ninety-v2, v3 and so on each time you publish changes.
const CACHE = 'ninety-v1';
const SHELL = [
  '/',
  '/index.html',
  '/styles.css',
  '/app.js',
  '/manifest.json',
  '/content/questions.json',
  '/content/weeks.json',
  '/content/tips.json',
  '/vendor/jspdf.umd.min.js',
  '/icons/icon-192.png',
  '/icons/icon-512.png',
  '/icons/apple-touch-icon.png'
];

self.addEventListener('install', (event) => {
  event.waitUntil(
    caches.open(CACHE).then((c) => c.addAll(SHELL)).then(() => self.skipWaiting())
  );
});

self.addEventListener('activate', (event) => {
  event.waitUntil(
    caches
      .keys()
      .then((keys) => Promise.all(keys.filter((k) => k !== CACHE).map((k) => caches.delete(k))))
      .then(() => self.clients.claim())
  );
});

self.addEventListener('fetch', (event) => {
  const req = event.request;
  const url = new URL(req.url);
  if (req.method !== 'GET' || url.origin !== self.location.origin || url.pathname.startsWith('/api/')) {
    return;
  }
  if (req.mode === 'navigate') {
    event.respondWith(fetch(req).catch(() => caches.match('/index.html')));
    return;
  }
  event.respondWith(
    caches.match(req).then((hit) => {
      const fresh = fetch(req)
        .then((resp) => {
          if (resp.ok) {
            const copy = resp.clone();
            caches.open(CACHE).then((c) => c.put(req, copy));
          }
          return resp;
        })
        .catch(() => hit);
      return hit || fresh;
    })
  );
});

self.addEventListener('push', (event) => {
  let data = {};
  try {
    data = event.data ? event.data.json() : {};
  } catch {
    data = {};
  }
  event.waitUntil(
    self.registration.showNotification(data.title || 'Your 90 days', {
      body: data.body || 'Drink or no drink today? Tap to mark it.',
      icon: '/icons/icon-192.png',
      data: { url: data.url || '/?mark=today' }
    })
  );
});

self.addEventListener('notificationclick', (event) => {
  event.notification.close();
  const path = (event.notification.data && event.notification.data.url) || '/?mark=today';
  const target = new URL(path, self.location.origin).href;
  event.waitUntil(
    self.clients.matchAll({ type: 'window', includeUncontrolled: true }).then((list) => {
      for (const client of list) {
        if ('focus' in client) {
          client.postMessage({ type: 'mark-today' });
          return client.focus();
        }
      }
      return self.clients.openWindow(target);
    })
  );
});
manifest.json · Makes the app installable. Change name and short_name when you pick the final name.
{
  "name": "The 90 Day Alcohol-Free Guide",
  "short_name": "90 Days",
  "description": "Your why, your game plan and a daily drink or no drink tracker, by the creator.",
  "start_url": "/",
  "scope": "/",
  "display": "standalone",
  "background_color": "#FFFFFF",
  "theme_color": "#E0338A",
  "icons": [
    { "src": "/icons/icon-192.png", "sizes": "192x192", "type": "image/png", "purpose": "any maskable" },
    { "src": "/icons/icon-512.png", "sizes": "512x512", "type": "image/png", "purpose": "any maskable" }
  ]
}
package.json · Two libraries for the server functions. The app itself uses no npm packages.
{
  "name": "ninety-days",
  "private": true,
  "type": "module",
  "engines": { "node": ">=18" },
  "dependencies": {
    "@supabase/supabase-js": "^2.45.0",
    "web-push": "^3.6.7"
  }
}
.env.example · Names only. Put the real values in Vercel, under Project Settings, Environment Variables. Never commit real values.
# Supabase: Project Settings, API
SUPABASE_URL=
SUPABASE_SERVICE_ROLE_KEY=

# From: npx web-push generate-vapid-keys
VAPID_PUBLIC_KEY=
VAPID_PRIVATE_KEY=
# Your contact, for example mailto:you@yourdomain.com
VAPID_SUBJECT=

# Random string, 32 characters, also set as the x-cron-secret header in cron-job.org
CRON_SECRET=

# One or more access codes separated by commas
ACCESS_CODES=
content/questions.json · Your 10 questions with the suggested edits to questions 1, 2, 3 and 7. Change the wording if you prefer.
{
  "sections": [
    {
      "id": "why",
      "title": "Before you start: your why",
      "questions": [
        { "id": "q1", "text": "Why am I doing 90 days alcohol-free?" },
        { "id": "q2", "text": "What's one thing I want to prove to myself in these 90 days?" },
        { "id": "q3", "text": "How am I going to feel once I've completed 90 days?" },
        { "id": "q4", "text": "Am I going to tell people I'm doing this? Who?" },
        { "id": "q5", "text": "Who can I text if this gets difficult?" }
      ]
    },
    {
      "id": "plan",
      "title": "Your game plan",
      "questions": [
        { "id": "q6", "text": "What social events have I got coming up where I'd normally drink?" },
        { "id": "q7", "text": "When I'm out, what non-alcoholic drink will I order instead?" },
        { "id": "q8", "text": "What will I say if someone asks why I'm not drinking?" },
        { "id": "q9", "text": "If I want to leave early, what's my exit plan?" },
        { "id": "q10", "text": "What will I do instead on the nights I'd normally drink?" }
      ]
    }
  ]
}
content/weeks.json · Weeks 1 to 4 come from your guide. Weeks 5 to 13 are placeholders: replace every WRITE line with your own words before launch.
[
  { "week": 1, "name": "The Adjustment", "noticed": ["Sleep gets better fast.", "Hangovers disappear.", "Mood can dip before it lifts."], "focus": "Rest.", "question": "What surprised me most this week?" },
  { "week": 2, "name": "The Dip", "noticed": ["Skin starts to clear.", "Energy is patchy.", "The feelings show up."], "focus": "Lean on people, don't isolate.", "question": "What am I most looking forward to?" },
  { "week": 3, "name": "The Shift", "noticed": ["Mood becomes steady.", "You notice what you actually enjoy.", "Social stuff gets easier."], "focus": "Find a replacement ritual. For me, it was movement.", "question": "What does a good Saturday morning look like without a hangover?" },
  { "week": 4, "name": "The Glow Up", "noticed": ["You feel like yourself again.", "Confidence feels real.", "You see who's really in your corner."], "focus": "Flick back to your why.", "question": "What do I want to keep doing after day 31?" },
  { "week": 5, "name": "WRITE: week 5 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 6, "name": "WRITE: week 6 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 7, "name": "WRITE: week 7 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 8, "name": "WRITE: week 8 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 9, "name": "WRITE: week 9 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 10, "name": "WRITE: week 10 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 11, "name": "WRITE: week 11 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 12, "name": "WRITE: week 12 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" },
  { "week": 13, "name": "WRITE: week 13 name", "noticed": ["WRITE", "WRITE", "WRITE"], "focus": "WRITE", "question": "WRITE" }
]
content/tips.json · Your disclaimer, hard-day ideas, bar lines and check-in questions as written. Lines marked WRITE are for you to write.
{
  "disclaimer": "This guide is based on my personal experience. It is not medical advice. If you're physically dependent on alcohol, stopping suddenly can present complications, so seek professional help.",
  "welcome": "WRITE: your welcome for the 90-day version. Your original starts: I'm the creator. I've been alcohol-free for over two and a half years.",
  "hardTips": [
    { "title": "Discomfort doesn't mean it's wrong.", "text": "WRITE: one sentence explaining this." },
    { "title": "Most of the fear isn't your own.", "text": "WRITE: one sentence explaining this." },
    { "title": "Confidence comes after, not before.", "text": "WRITE: one sentence explaining this." }
  ],
  "hardClose": "When it gets really hard, text the person you named:",
  "barLines": [
    "I'm not drinking tonight.",
    "Can I get a soda, lime and loads of ice? In a short glass.",
    "I feel so much better without it."
  ],
  "trackerTagline": "What gets measured gets managed.",
  "checkin": [
    "What did I overcome this week and what got me through it?",
    "Did anything catch me off guard and what will I do differently?",
    "What's coming up next week that I need a plan for?"
  ],
  "drinkDay": "WRITE: a short, kind line for drink days.",
  "day31": "Well done. Made it to 31. WRITE: one line about the next 59 days.",
  "day90": "WRITE: your day 90 message.",
  "signoff": "Come find me @yourhandle"
}
7. Test + launch

Test on real phones before selling

iPhone

  • Phone runs iOS 16.4 or later (research note, unconfirmed: needed for web push)
  • Open the app link in Safari, enter a wrong code and see the error, then enter the right code
  • Add to Home Screen, then open the app from the new icon
  • Answer the questions in the Home Screen app and confirm the answers are still there after closing and reopening it
  • Tap 'Turn on daily reminder' and see the permission prompt only after the tap
  • Set the reminder to the next hour, lock the phone and confirm one notification arrives
  • Tap the notification and land on Today
  • Download the PDF and save it to Files, then check all answers are in it
  • Turn on airplane mode and confirm the app opens with your data
  • Set Larger Text in iPhone settings and confirm nothing is cut off

Android or desktop

  • Chrome on Android shows the Install app button, and the installed app opens full screen
  • The reminder arrives at the chosen hour, and tapping it opens Today
  • The PDF downloads and opens
  • Desktop Chrome or Edge: every screen works with keyboard only, focus outline visible
  • Desktop Firefox: the app works, and reminders work or the app shows a clear message
  • Turn reminders off in Settings and confirm the row is gone from the Supabase push_subs table

The full journey

  • Make a test purchase in Lemon Squeezy, receive the access card PDF, then refund it
  • Unlock, read the disclaimer, confirm Continue stays disabled until the box is ticked
  • Use ?debug=1 to set the date: day 1 shows the week 1 tip, day 7 shows the check-in, day 8 shows the week 2 tip
  • Mark a drink day: your drink day message, the name from question 5 and the hard-days link appear, and the no-drink count does not reset
  • Leave a day unmarked: the 'You didn't mark yesterday' card appears the next day
  • Day 31 shows the milestone once, day 90 shows the celebration once
  • The final PDF contains the why, game plan, 90-day grid, every check-in and the disclaimer footer
  • Save a backup file, reset everything, restore the backup and confirm all data returns
  • cron-job.org history shows hourly calls with status 200, and a call without the secret returns 401
  • No WRITE placeholder text appears anywhere in the app or the PDF

Launch

Your timeline is one month: about 3 weeks to build and 1 week of beta testing. Your buyers are women finishing Dry January who want to keep going. If launch day falls in January, open sales in the last 10 days of January, when your audience is close to day 31. If it falls later, launch to your current followers, then plan a second, bigger push for the next January: give away the free Dry Jan Survival Guide early in the month, and point its updated last page to the 90-day version. Post from your @yourhandle account in your own voice. Show the app on screen, not just a mockup.

8. Pricing research

Recommended: $19 one-time, no subscription.

Prices below are copied from the research notes as listed. Products whose prices the research could not confirm are left out. No 1:1 coaching prices were found.

ProductTypeListed price
Printable Dry January Tracker: 31 Day Habit Checklist PDF (Etsy)Printable PDF$1.25
30-Day No Alcohol Challenge Tracker Printable (Etsy)Printable PDFSale Price $1.06, Original Price $1.41 (25% off)
100 Day Alcohol Free Tracker Printable, UK A4 PDF (Etsy)Printable PDF$4.90
90-Day Sober Challenge Template / Sobriety Daily Tracker (Etsy)PDF$8.35
Sobriety Workbook Bundle (Etsy)PDF bundleSale Price $9.13, Original Price $15.23 (40% off)
90-Day Sobriety Journal: Alcohol-Free Workbook & Tracker (Etsy)PDF$10.93
Christian Recovery Journal for Women, 90-Day Sobriety Journal (Etsy)Printable PDF$12.99
90 Day Sobriety Journal, Alcohol Free Workbook (Etsy)PDF$14.99
Sobriety Journal / Daily Sobriety Progress Notebook (Etsy)Physical notebookSale Price $14.79, Original Price $26.90 (45% off)
Try Dry (Alcohol Change UK)AppNo charge and no in-app purchases
Sober TimeAppFree download, Premium $4.99 a month or $29.99 to $49.99 a year
I Am SoberAppFree core app, Sober Plus $9.99 monthly or $39.99 annually
SunnysideApp subscription$12 a month, $29 a quarter or $99 a year; $99 a month for Sunnyside Med
ReframeApp subscription$13.99 to $24.99 a month or $59.99 to $119.99 a year (US App Store)
This Naked Mind Boxed Set (Annie Grace)Printed booksPaperback $39.00
Club Soda, How to Drink MindfullySelf-paced online course£50.00
One Year No Beer, 90-day alcohol-free challengeOnline programNEW MEMBER PRICE £109

Prices as listed when this guide was made. Some are sale prices. Check each page before quoting.

The Dry Jan Survival Guide

Free

Your existing 31-day PDF. Its last page links to the 90-day version.

The 90 Day Alcohol-Free Guide

$19 one-time

Fill-in why and game plan with PDF download, a daily drink or no drink tracker, daily reminders, 13 weeks of tips and check-ins. Optional launch-week price of your choice, for example $15.

90 days with the creator

Check current pricing (no coaching prices found in research)

The app plus higher-touch support from you, for example group check-ins. Price it after you research sober coaching prices.

Later: printed journal or a second 90 days

Check current pricing

A print version for the buyers who want paper, or a follow-on for buyers who finish day 90.

Why this price

Sources

Made by Saha Synergy on 2026-12-01. Want help building it? Reply to your delivery email or visit sahasynergy.com/idea-to-finished-product.