Projects / Fresh.win
CASE STUDY · PREDICTION PLATFORM

Fresh.win

Fresh.win is a sports prediction platform centered around football competitions from Europe’s top leagues. Instead of gambling with money, users compete through probability-based match predictions, rankings and community challenges. The platform integrates gamification systems such as daily rewards, referral programs, streak mechanics and seasonal competitions to maximize engagement while promoting responsible play.

reactgamificationtailwind
Role
Solo · full-stack
Timeline
2024 · 12 weeks
Platform
Web
Type
Prediction Platform
fresh-win.app
primary screenshot · Fresh.win
THE PROBLEM

The sports betting market has a responsible-play problem: platforms engineered for money wagering attract addictive behavior and exclude casual fans.

Fresh.win targets the large audience of football fans who want to test their match knowledge and compete socially but are put off by gambling platforms. The referral program and streak mechanics are designed to drive organic growth while daily rewards create return habits.

  • Gambling platforms harm casual fans. Money-based prediction attracts addictive behavior and excludes fans who just want to compete.
  • Free platforms lack depth. Without real stakes, engagement loops collapse after week one — there's nothing to come back for.
  • Referral fraud is rampant. Unprotected referral systems get abused immediately after public launch.

Football fans avoiding gambling

Sports fans who want competitive prediction without financial stakes — just reputation and bragging rights

150+
beta users
4 days
avg. active streak
40%
referral acquisition
THE SOLUTION

no money, just reputation.

React + Tailwind frontend, Node.js API, PostgreSQL for relational data (users, predictions, referrals, leaderboards). A points engine processes match outcomes asynchronously via a job queue. Referral codes use HMAC-signed user ID tokens with configurable expiry. The gamification engine is event-driven: match resolution emits events consumed by score updater, streak checker, badge evaluator, and leaderboard recalculator services.

01

Predict

Submit match outcome predictions daily.

02

Earn

Points awarded based on prediction accuracy.

03

Streak

Daily rewards compound with active streaks.

04

Compete

Seasonal leaderboards and friend leagues.

in progress
Before
manual workflow
fragmented tools · high manual overhead
After
fresh-win.app
single unified product · fast & automated
KEY FEATURES

Built around how football fans avoiding gambling actually work.

FEATURE 01

Gamification Engine

An event-driven points system that processes match results asynchronously, triggering streak recalculation, badge evaluation, and leaderboard refresh in one idempotent pipeline.

  • Conservative reward tuning refined through beta feedback
  • A/B testable reward rules via event-driven architecture
gamification-engine
screenshot · Gamification Engine
FEATURE 02

Referral Attribution Pipeline

HMAC-signed referral tokens with configurable expiry, combined with rate limiting, email verification, and IP-based identity checks to prevent abuse.

  • Fraud prevention built before public launch, not retrofitted
  • Attribution tracking survives multi-step conversion flows
referral-attribution
screenshot · Referral Attribution Pipeline
FEATURE 03

Seasonal Competition System

PostgreSQL aggregation pipelines compute seasonal leaderboards and cumulative standings with a Redis-cached layer for high-traffic match windows.

  • High query performance during peak match traffic
  • Seasonal bracket logic modeled for clean state transitions
seasonal-competition
screenshot · Seasonal Competition System
TECHNICAL CHALLENGE

Hard problems solved.

The points engine listens to match result events and triggers a pipeline: score update → streak recalculation → badge evaluation → leaderboard refresh. Each step is idempotent to handle retries safely. Daily reward distribution runs as a scheduled cron job with deduplication via a processed-date key per user. Referral fraud prevention combines rate limiting, email verification, and IP-based identity checks.

What made it hard

  • Designing a gamification engine that is engaging without being so generous that leaderboards lose meaning.
  • Building a fraud-resistant referral tracking and attribution pipeline to prevent abuse.
  • Implementing seasonal competition brackets and cumulative leaderboards with high query performance.
  • Daily reward distribution system that is fair, verifiable, and resistant to timing manipulation.
  • Balancing reward generosity vs. competition integrity — tuned through beta user feedback.
architecture.ts
1 const frontend = [ "React", "Tailwind CSS" ];
2 const backend = [ "Node.js", "Express", "PostgreSQL" ];
3 const gamification = [ "Event-driven engine", "HMAC tokens", "Redis cache" ];
4 const infrastructure = [ "Cron jobs", "Job queue", "Rate limiting" ];
THE STACK

Technologies used.

Frontend
ReactTailwind CSS
Backend
Node.jsExpressPostgreSQL
Gamification
Event-driven engineHMAC tokensRedis cache
Infrastructure
Cron jobsJob queueRate limiting
WHAT THIS PROVES

What Fresh.win demonstrates.

Gamification design

Designed and tuned a complete engagement loop — points, streaks, badges, leaderboards — validated with 150+ beta users.

Fraud prevention

Built a multi-layer referral fraud system using HMAC tokens, rate limiting, and IP checks before public launch.

Relational data modeling

Chose PostgreSQL over a document store and leveraged its aggregation pipelines for complex leaderboard queries.

Event-driven architecture

Decoupled the points pipeline into independent, idempotent services that make reward rule A/B testing straightforward.

WORK WITH ME

Want to build something like this?

Bring me your idea or half-built project. We'll scope it, design it and ship it — using the same workflow behind Fresh.win.

Next case study EduMation