Why I built it
Loterita is named for my grandmother. Her Lotería nights are the reason this app exists.
Lotería is the Mexican picture-card game families play at gatherings, fiestas, and holidays. A cantor calls out cards like El Gallo, La Sirena, and La Rana, often with a short rhyme, and everyone marks the matching pictures on their tablas, usually with beans, until someone shouts "¡Lotería!"
I didn't want to replace that table with a screen. I wanted to keep it going. The picture I designed around is simple: someone sets the paper tablas on the table, opens Loterita, picks a pattern, presses Auto Call, and puts the phone in the middle. The phone plays the cantor, so everyone else gets to play.
What that meant for the design
- Free, and works offline. The traditional game costs nothing and keeps working without a connection, because a family game shouldn't depend on Wi-Fi.
- Spanish first. Spanish is the default, with English alongside it, so grandparents and grandkids can both use it.
- Paper still counts. Tablas and calling cards print at real, fixed sizes, so what comes out of the printer looks like the real thing.
- Your own deck. People can turn their own photos into a custom deck for a wedding, a birthday, Christmas, or a classroom.
What it does
- A digital cantor that shuffles the deck and calls it automatically or by hand, with a big-screen mode for the middle of the table and an optional Spanish voice.
- Prizes along the way. A full tabla wins the round, with smaller prizes like Four Corners and Chorro claimed along the way.
- A ¡Lotería! check. Enter a tabla number to see its called cards marked and whether it really wins.
- Printable tablas generated fresh and fair, exported as print-ready PDFs in Letter or A4.
- A custom deck editor for cropping, rotating, and arranging your own photos.
- Picks up where you left off, even after a reload or a dropped connection mid-game.
How it's built
I designed and built Loterita on my own: a Next.js and TypeScript web app, a Supabase and PostgreSQL backend, and a small worker that processes photos and prepares print files. The game itself runs entirely on the device, which is what lets it work offline.
The engineering I'm proudest of is the part that keeps it trustworthy:
- Fair, repeatable tablas. Tablas come from a seeded random generator, so every card gets used evenly across a set, and the same inputs always produce the same tablas.
- The server double-checks everything. The backend independently verifies tablas instead of trusting what the browser sends, and the database is locked down so every change goes through vetted rules.
- Rules tested exhaustively. The win-checking logic is tested against every possible board, not just a handful of examples.
- A game state that's never lost. Every call is saved before it's shown, and only one tab can run a game at a time.
- Print at real-world size. The same inputs always produce an identical PDF, at the same physical size, whether it's made in the browser or on the server.
It's covered by automated tests at every layer, including database tests and browser tests across Chrome, Firefox, and Safari's engine.
Where it stands
Loterita is a feature-complete web beta. Up next: multiplayer rooms and a native app.








