DEV Community

jithu baiju
jithu baiju

Posted on

built a stranger chat app from scratch — and what we learned

My friend and I just launched Sparq — an anonymous stranger chat app with interest-based matching. This is the story of how we built it, what broke, what we learned, and the scrappy solutions we used when things didn't go as planned.

What we built and why

Omegle shut down. Every alternative we tried was either full of bots, had terrible mobile UX, or felt abandoned. So we decided to build something ourselves — clean, mobile-first, face verification ,games and actually fun to use.
Sparq matches strangers by shared interest tags. Free users get interest-based matching. VIP users unlock location-based matching — city first, then state, then country. The idea is that when two people share interests or location, conversations actually go somewhere instead of dying in 10 seconds.

The tech stack

  • Frontend —HTML, CSS, JavaScript.
  • Backend — Node.js with Socket.io for real-time chat and matchmaking
  • Database — Supabase (free tier, saved us completely)
  • Hosting — Vercel for frontend, Render for backend
  • Auth — JWT tokens, custom implementation

The matching algorithm

This was the hardest part to get right. The queue system works like this — when a user joins the search, we put them in a Map with their interests, location, and gender filter. Every new user who joins triggers a findMatch() scan across the entire queue.
For free users we match purely by shared interest tags. The more tags in common, the higher priority the match. For VIP users we first try to match within the same city with shared interests, then same city without interests, then same state, then same country, then fall back to global matching. This way VIP users almost always meet someone nearby.
We also built a boost system — users who have been waiting longer get priority in the queue so nobody waits forever.

What broke along the way

  • Render's free tier sleeps — our backend goes to sleep after 15 minutes of inactivity and takes 30 seconds to wake up. Early users thought the app was broken. Fixed it with UptimeRobot pinging the backend every 5 minutes.

  • The cold start problem — with a small user base, wait times for matching can get long. We built "opener rooms" — topic-based group spaces users join while waiting so the app never feels completely empty.

Where we are now

Just launched. Small user base, still growing. The core experience works — two strangers match, have a conversation, sometimes something interesting happens. That's the whole point.

If you're a developer reading this and want to try it — we'd genuinely love feedback on the first session experience. Cold start feedback from a fresh set of eyes is the most valuable thing for us right now.
Link: https://sparq-flax.vercel.app/

Top comments (0)