Games with AI

How to add a leaderboard, quests and a store to a web game

How to add a leaderboard to a web game that players cannot cheat, plus daily quests and a store with server-checked prices. No backend to write.

To add a leaderboard to a web game without writing a backend, ask the iDos Games AI coder for one and set its rounds and rewards in the dashboard: the server counts scores and ranks, and the game only submits results. Quests and a store work the same way. All three are ready systems on our server, so scores cannot be faked from the browser and prices cannot be edited by a player.

These three systems answer three reasons to come back tomorrow: to beat others, to finish today's tasks and to get something new. Together they turn a game people try once into a game they open every day. Below is how to add each one, how to keep it fair, and how to connect them.

Four ways to add a leaderboard

WayShared between playersSafe from fake scoresWork for you
localStorage in the browserno, only on one devicenoa few lines
Your own database (Firebase and similar)yesonly with careful rules and server checksdays, then maintenance
A game portal SDKyes, inside that portaldepends on the portalmoderate, tied to one site
A ready system on iDos Gamesyes, on every deviceyes, limits on the serverone request and dashboard settings

The common mistake with the first two is trusting the number the browser sends. Anyone can open the developer tools and submit a score of one billion. A fair board needs a server that decides what counts.

Leaderboard

Ask the AI coder:

Add a weekly leaderboard by best score.

It installs the leaderboard system and teaches the game to submit the result. Then open Live Operations → v2 → Leaderboard in the dashboard and set:

  • the round: a board repeats in cycles (for example every week), runs on a schedule or as a chain of rounds;
  • how the score counts: the sum of all results, the best result, the best time or the last value;
  • rewards: for rank at the end of the round, and points milestones inside it ("earn 1000 points this week").
Leaderboards
12 450
320
Weekly!
Season
My score12 840
Rank#7
Ends in 2d 04:13
Rewards
Play
ShadowFox25 120
2Mira22 980
3KnightOwl19 400
4Pixel_Pete15 210
5Luna14 030
6Arrow13 115
7You12 840
8Grizzly11 900
Every enabled board is a tab; the badge means a reward is waiting.
The player card: score, rank and the countdown to the end of the round.
Rank and points rewards open from here; "Play" leads to the game mode.
Medals for the top three, the player is highlighted in the list.
Example. The leaderboard screen: the player card with the round timer and the top list.

Make it cheat-proof. A board takes a number from the game only through a ClientScore source, and that source has limits: a maximum per submission, per day and a pause between submissions. Set them to what a real player can achieve. If your best testers score 5,000 a round, a cap of 20,000 per submission stops nobody honest and blocks the obvious fakes.

Several boards can run at once: each enabled board is its own tab with its own round and rewards, for example a weekly board and an all-time board.

Quests

Quests are already in every new project. In Live Operations → v2 → Quest create a cycle and a few tasks:

  • Cycles are tabs for players: daily, weekly, achievements, each with a timer to the next reset.
  • Tasks count actions: "defeat 20 monsters", "win 3 rounds", "buy anything in the store".
  • Chains: a quest can require another to be done first, which builds a short storyline.
  • A points track with chests runs alongside, plus a bonus for finishing a group of tasks.

Then tell the AI coder what to count:

Count monsters_defeated every time a monster is defeated.

Good first set: three daily quests that take five minutes in total, one weekly quest that needs a few sessions, and achievements for milestones. Daily quests that take an hour feel like a chore and push players away.

Store

Ask the AI coder:

Add a shop.

Then in Live Operations → v2 → Store create offers and put them on a storefront. The store is a tree: storefront, sections, slots, offers. An offer is sold only through a slot, and a slot can rotate offers on a schedule, like a daily shop that every player sees the same way on every device.

Shop
12 450
320
Daily1
Currency
Packs
Daily deals Refreshes in 15:40:12
Daily gift
FREE
Hero sword
1 200
Gear chest
90
Sold out
500 coins
$0.99
Best value1 200 coins
$1.99
x2 first buy
Storefronts are tabs; the badge counts free offers waiting.
Rotation timer: the server swaps the offers of the slot when it runs out.
A free daily gift shines until it is claimed.
Sold out: the limit for this window is spent.
Ribbons and the first-purchase bonus come from the offer settings.
Example. The store screen as a player sees it, in the default look. The look is changed in src/ui.config.ts.

What a price can be:

The player paysHow it works
game currency or itemstaken from the player's balance
Aspisthe platform currency; the player confirms each purchase on idosgames.com, and each sale brings you income
real moneya purchase in the app store, the server checks the receipt
watching an adin the mobile app, the player spends an ad view they earned

A free daily gift with a limit is the best first offer: it brings players to the store every day and costs you nothing.

Connect the three systems

The real effect comes when they feed each other:

  • A quest for the store: "buy anything in the store" teaches new players where it is. The server counts purchases by itself.
  • Store rewards for the top of the leaderboard: a frame, a skin or a chest that money cannot buy.
  • A daily quest for a ranked round: players who would not compete on their own get a reason to try.
  • Quest rewards in store currency: finishing tasks feeds the shop, and the shop feeds the next round.

How to tell it works

Watch three numbers in the game's analytics in the dashboard:

  • how many players come back the next day: quests and login rewards should lift it;
  • what share of players opened the store at least once: if almost nobody, make the free daily gift more visible;
  • how many daily quests get finished: if very few, the tasks are too long.

Roll them out one by one

Each system's tab appears for players only after it is configured, so you can add them in any order without empty screens. A sensible order for a new game:

  1. Quests first: they are already in the project and give players goals from day one.
  2. Leaderboard next, once the scoring feels fair in playtests.
  3. Store last, when players have something to spend on.

Settings are live data: you can change rewards, prices and limits in the dashboard without building the game again. If you are building with an agent instead of the AI coder, the same systems are available to it over MCP: see how to make a game with Claude Code. And when the store starts selling, read how to monetize a browser game.

Aidos Ryskeldinov

About the author

Founder of iDos Games

Lifelong gamer and tech enthusiast. Since 2020 I have been building and shipping cross-platform games and apps, and today I'm building iDos Games: a platform where anyone can make a game with AI, put it live at its own link and earn from it. Here I share how to make games faster and easier than you'd think.

Frequently asked questions

Do I need my own server for a leaderboard?

No. The iDos Games server counts scores, ranks and rewards; the game only submits results and shows the ranking.

Can players cheat the leaderboard?

Not when the board is set up right. A board takes a number from the game only through a source with limits: a maximum per submission, per day and a pause between submissions.

Why not just keep high scores in localStorage?

localStorage is per browser: other players never see the score, and it is gone when the player clears data or changes devices. A shared ranking needs a server.

Are quests already in my project?

Yes. Quests are part of every new project; their tab appears for players as soon as at least one quest is set up.

Can I sell items for real money?

Yes. Store offers can be priced in game currency, in Aspis (the platform currency), in real money through the app stores, or for watching an ad in the mobile app. The server checks every price.

Learn more in the documentation

Make your own game

Describe the idea in a sentence - the AI coder builds it, and it goes live at its own link.

All articles