For administrators
The admin page is where you create accounts, set plans and record payments, see who works where, and look up or fix any data.
Only people whose email is in the site’s ADMIN_EMAILS setting are administrators. They get a My books / Admin switch at the top of the menu (and in the account menu): Admin opens the admin portal, and My books goes back to your own dashboard. Each side reopens the page you were last on. Nobody can become an admin from inside the app. While no admin account exists, the first one is created from the sign-up page with a link emailed to an ADMIN_EMAILS address (it works for 1 hour), so set up the site’s email first.
One of them is the developer: the address in DEVELOPER_EMAIL, or the first in ADMIN_EMAILS if that’s not set. Only the developer can see people’s books, receipts, files and chats (Tree, People map, Data, Messages, Change log, Security and who was emailed). Other admins create accounts, set plans, record payments and check email setup, without seeing anyone’s data. They can replace a lost setup link, but a password reset link for an account that’s already set up (which would let them into it), or setting up another admin, is the developer’s alone. See Security and encryption.
Create an account
- 1Go to Admin and choose Create account.
- 2Enter their name and email, and how many businesses they can have (or No limit).
- 3Choose Paid to record the first month now (the amount is worked out from your price), or Not billed.
- 4Send them the setup link. If the site’s email service is set up, it’s emailed too. They open it, choose a password, and sign in. The link works once and expires after 7 days; a lost link can be replaced from the account’s ⋯ menu (New setup link).
Plans and payments
- Price per business: the monthly price, used to fill in payment amounts. If it includes tax (for example 13% HST), enter that too, so owners’ books get the right tax credit.
- Record payment… (in an account’s ⋯ menu, or the button next to accounts that are due or overdue): choose how many months and businesses; the amount fills in and you can change it, and add a note like an e-Transfer reference. The paid-through date moves forward from where it was, or from today if it had ended. It’s added to the owner’s books as an expense automatically (split across their businesses; they can turn this off), and they’re emailed a receipt once email is set up.
- Businesses allowed… raises or lowers the limit. Lowering it never removes businesses; they just can’t add more. Giving a team member businesses lets them own some.
- Paid-through date… corrects the date by hand, or stops billing an account.
- Show → Needs payment lists accounts due within a week or overdue. Overdue accounts’ businesses are view-only until you record a payment. The summary cards show paying accounts, businesses billed and monthly revenue.
Turn an account off
Turn off account signs them out everywhere, stops them signing in and stops their quick-add devices. Their data stays, and people they shared businesses with keep working in them. Turn back on restores access.
Email setup and the email log
Admin → Email checks that email can go out and says how to fix anything that stops it. The free, quick way to send is a Gmail account: turn on 2-Step Verification, create an app password at myaccount.google.com/apppasswords, and add GMAIL_USER (the Gmail address) and GMAIL_APP_PASSWORD (the app password, not your normal password). Gmail sends up to about 500 emails a day, and they come from that address. With a domain of your own you can use Resend instead: RESEND_API_KEY and EMAIL_FROM (an address on a domain you’ve verified in Resend; its test sender only delivers to your own Resend address). The page also checks scheduled emails (CRON_SECRET, and whether they go out on time). Send a test email to me shows exactly what Gmail or Resend answered. Below, every email The Money Tracker tried to send in the last 90 days is listed as Sent, Failed (with the reason) or Not sent. Change these settings in Vercel → Settings → Environment Variables (Production), then redeploy.
Scheduled emails
Reports, alerts and reminders (all opt-in, set by each person in Settings → Emails) go out through the site’s email (Gmail or Resend; both free at The Money Tracker’s volume). They need CRON_SECRET set in Vercel, and three free schedules start them:
- Every 5 minutes. This is what makes them go out on time: reports at the hour people pick, alerts within 5 minutes and reminders at 9:00 AM Toronto time. On Supabase, Admin → Email → Supabase’s scheduler → Set it up has the database itself call every 5 minutes (Supabase Cron, included with Supabase; your CRON_SECRET is kept in Supabase Vault), so nothing else is needed. Otherwise use a free scheduler like cron-job.org; Admin → Email has the exact steps and shows when it last ran. If both run, each email still goes out once.
- Hourly backup from GitHub (the “Hourly emails” workflow, with a repository secret named CRON_SECRET holding the same value). GitHub often runs it late or skips hours, so it only matters if the 5-minute calls stop.
- Daily fallback from Vercel: once a day between 9 and 10 AM Toronto time. It does nothing while the 5-minute calls arrive.
- Each report goes out once even if runs overlap, a missed one catches up with only the latest, and every attempt is in the email log. As an admin you can also turn on Accounts due for payment in Settings → Emails.
Voice and video calls
Every chat has voice and video call buttons, run by Daily (daily.co). To turn them on, create a free account at dashboard.daily.co, copy the API key from Developers, add it in Vercel → Settings → Environment Variables as DAILY_API_KEY (Production) and redeploy. The free plan includes 10,000 participant minutes a month; a 30-minute call between two people uses 60. Until the key is set, only admins see the buttons (they explain these steps). See Voice and video calls.
Tree
- Admin → Tree (developer only) shows everything as one tree: The Money Tracker, then each owner, their businesses, and inside each business its people (manager, co-managers, employees), pending invitations, quick-add devices, recurring payments and transactions by year and month. Each owner also has their lists (purposes, payment methods, merchants, budgets, saved fees) and plan payments.
- Explorer works like a file browser: click the arrows (or use the arrow keys) to open branches, and click a row to see its numbers (transactions, money in and out, net) and facts in the panel beside it, with buttons that open the matching records in Data. On a phone the details slide in. Find keeps only the matches and what’s above them.
- Diagram draws owners, businesses and people as connected cards. With everyone shown, each owner starts folded: use the round button on a card to open or fold what’s under it, or pick one owner to see all of theirs. Zoom in or out, or Fit it to the width.
People map
Admin → People map (developer only) shows every business owner (manager) with their businesses, and under each business who works in it: co-managers, employees, pending invitations and quick-add devices, with how many transactions each person added there. Switch to By person to see everywhere one person works. Every name and number opens the matching records in Data.
Data: every table
- Admin → Data (developer only) lists the database’s tables (accounts, business access, businesses, transactions, fees, recurring payments and the rest) with how many rows each has. Pick a table to see its rows; scroll sideways for more columns.
- Search looks in the table’s text (or paste an ID). Filter adds conditions like “Amount more than 100” or “Business is Acme”. Click a column heading to sort by it. The address keeps it all, so you can bookmark or share a view with another admin.
- Whose data narrows every table to one owner’s books and the people working in them.
- Click a row to open it. Links (a transaction’s business, who added it…) open the record they point to, and Linked from lists everything that points at it, like a business’s transactions or an account’s access, so you can trace any record.
- Edit changes the fields that can safely be changed, with an optional reason. IDs, owners and worked-out totals are locked. Links must stay in one owner’s books, and fees are worked out again when an amount changes. Edited transactions show you as the last person who edited them.
- Add creates rows in tables where that makes sense, for example giving someone access to a business. Delete first shows what goes with the row and what loses its link to it. Deleting an account can’t be undone and asks you to type its email.
- Passwords, sign-in tokens, two-step secrets and the secret part of links are never shown, not even to admins.
Change log
Admin → Change log (developer only) lists every change made in Data: who made it, when, the reason, and each field before and after. Undo puts a change back if nothing has changed the record since, and Restore brings back a deleted record together with the rows deleted with it and the links that were cleared. Deleted accounts, sign-ins, invitations and devices can’t be restored.
Security and encryption
Admin → Security (developer only) shows who can see people’s data and whether it’s encrypted. With encryption on, notes, chats, receipts, files, invoice messages, customers’ emails and addresses, invoicing details and the email log’s subjects are stored scrambled, with a key that lives only in Vercel. Someone with only the database (a backup, a leaked password or the Supabase dashboard) can’t read them; the app decrypts them for the people allowed to see each thing.
- 1Make a key: in Terminal, run openssl rand -base64 32.
- 2Save a copy in your password manager. Without the key, encrypted data can’t be read by anyone, you included.
- 3In Vercel → Settings → Environment Variables, add DATA_ENCRYPTION_KEY with it (Production and Preview, marked Sensitive) and redeploy. What’s already stored is encrypted in the background within minutes; the Security page shows what’s left and has Encrypt now.
To change the key, move the current one to DATA_ENCRYPTION_OLD_KEYS, put the new one in DATA_ENCRYPTION_KEY and redeploy. Remove the old one only once the Security page shows everything done.
The sign-in secret (BETTER_AUTH_SECRET) is a different one: it signs everyone’s sign-ins and the links in emails, and encrypts two-step sign-in secrets. The Security page says whether it’s strong. To change it without signing anyone out, make a new one the same way, add BETTER_AUTH_SECRETS with 1: and the new secret (Production and Preview, marked Sensitive), leave BETTER_AUTH_SECRET as it is, and redeploy. The Security page then shows two-step sign-ins moving to the new secret, and when the old one can go.
Still stuck? See Troubleshooting, or contact the person who runs this site.