Software Development
Building a Domain-Verified Institution Join Flow
Universities and colleges can offer Tracademic to their students, which means the app needs a way for a student to prove they actually belong to a given institution before that link is made. The first version of this flow worked, technically, but it trusted the wrong thing. This post is about why I rebuilt it as a two-step, domain-verified process instead.
The first version: pick your institution, get a seat
The original flow was as simple as it sounds: a student picked their institution from a list, and the account was linked immediately. It was fast, it demoed well, and it was wrong in a way that only becomes obvious once you think about who's actually making that claim. Nothing about "select an option from a dropdown" proves anything about the person selecting it. Anyone could claim to belong to any institution in the list, with no verification at all.
For a feature that's meant to represent a genuine relationship between a student and their institution, that's not a rounding error — it's the whole feature not actually doing what it claims to do.
Why that didn't hold up
The problem isn't really about malicious abuse, although that's part of it. It's that the entire point of an institution-linked account is trust: an institution offering Tracademic to its students is relying on that link being accurate, not just self-reported. A join flow that can't back up its own claim doesn't give an institution anything it can rely on, even if most students using it are acting in good faith.
Instant claiming also had no natural way to keep the relationship it created honest. Once claimed, there was no ongoing basis for the account being linked to that institution — it was accurate at best by coincidence, not by design.
The two-step fix
The fix was to stop treating institution selection as proof and start treating it as an intent that still needs verifying. The flow is now two steps: a student enters their institutional email address, and the account isn't linked to the institution until that specific email address has been verified — via a link or a code sent to that address, which only the person with access to that inbox can complete.
That single change moves the actual proof from "what a student clicked" to "what a student can prove they have access to," which is a much stronger claim. It also means the link between account and institution has a concrete basis that can be pointed to later, rather than resting on an unverified selection made once at signup.
Matching domains without naming names
The other half of the fix is matching the submitted email against a known set of institutional email domains, rather than trusting a free-text or dropdown claim on its own:
function isInstitutionalEmail(email, allowedDomains) {
const domain = email.split('@')[1]?.toLowerCase();
return allowedDomains.includes(domain);
}
This is deliberately the general shape of the check rather than any specific list — the point isn't which domains are on it, it's that the domain has to match before a verification email is even sent, and the institution link only completes once that email is confirmed. Two checks, not one: does the domain plausibly belong to this institution, and can this specific person prove they own an address on it.
Designing for the edge cases, not just the happy path
Once verification is real rather than assumed, you also have to think about what happens around it, not just at the moment it succeeds. A verification link needs to expire rather than stay valid indefinitely. A student who mistypes their email needs a clear way to try again rather than getting stuck. And because the whole flow adds friction compared to instant claiming, the messaging at each step has to explain why — otherwise it just reads as an app being slower for no reason, rather than an app doing something on the student's behalf that a dropdown never could.
None of this is complicated engineering. It's the kind of detail that's easy to skip when a feature is built quickly to demo well, and easy to regret once real institutions and real students are relying on it.
The takeaway
A feature that represents a claim about someone — "I belong to this institution" — needs a verification step that actually backs up the claim, not just a selection that's convenient to build first. Instant seat-claiming was faster to ship and looked identical in a demo, but it verified nothing. Moving to a two-step, domain-matched email flow made the feature slower by exactly one email round-trip, and turned it from something that looked like verification into something that actually is.
It's the same underlying instinct as the write-security work in Hardening Firestore Write Security in a Solo-Built App: don't trust a claim just because the client made it look easy to make.