TL;DR
- LeekCF-Hinter is a free, open-source (Apache-2.0) public API.
GET /v1/problems/{contestId}/{index}/hintsreturns 2 to 5 graded hints for a Codeforces problem: a small nudge first, the full solution last. No key, no account. Check it out: https://leekcf-hinter-api.leekcf.workers.dev . - Any extension, app, bot or person can use it. It is a plain public API with open CORS, so a browser extension can call it directly.
- LeekCF-Ratings already uses it today. Install the extension (Chrome or Firefox), open a problem and click Show Hints. You can watch the requests yourself in DevTools.
- 6,833 problems already have hints (25,788 hints across 1,176 contests), and about 1,640 more are queued. They should be done around November 5.
- It runs for $0: GitHub Actions, Supabase and Cloudflare Workers, all on free plans.
- The hints are written by Google's Gemini Flash models on the free tier, for cost reasons. They can be wrong.
The endpoint
curl "https://leekcf-hinter-api.leekcf.workers.dev/v1/problems/1850/A/hints?client=my-app/1.0"
{
"problem": { "id": "1850_A", "contestId": 1850, "index": "A", "name": "To My Critics", "rating": 800, "tags": ["implementation", "sortings"] },
"duplicateOf": null,
"hints": [
{ "level": 1, "content": "Since there are only three digits $$$a$$$, $$$b$$$, and $$$c$$$, there are only three possible pairs you can choose... Think about which pair will naturally produce the largest sum." },
{ "level": 2, "content": "..." }
],
"groundedInTutorial": true,
"generatedAt": "2026-10-31T15:18:37Z"
}
That is the whole contract. A 404 means "no hints for this problem (yet)". The root URL is a documentation page, and the OpenAPI spec is at /v1/openapi.json. Please add ?client=your-app/1.0 so usage can be counted per app, cache what you get, and stay under the rate limit (about one request per second per IP, after a small burst).
Anyone can use it
This is the point of making it an API: any extension, website, bot, editor plugin, script, or just you with curl can use it. There is no key to request and no signup, and the answers are open to browsers (CORS is *), so an extension or a web page can call it directly. Build your own "Show Hints" button, a Discord bot, a VS Code sidebar, a practice tracker. If you do, I would love to hear about it. **Check it out: https://leekcf-hinter-api.leekcf.workers.dev** (the root page is the documentation).
What a "hint" means here
Every problem gets 2 to 5 hints, depending on difficulty (roughly 2 for ratings up to 1000, up to 5 above 2000). They are written as a ladder:
- Hint 1 is one observation, such as what the limits imply or a special case worth checking.
- Hints 1 and 2 never name an algorithm. This is checked automatically, and an answer that breaks the rule is thrown away and regenerated.
- From hint 3 on, the hint may name the technique, the recurrence and the complexity.
- The last hint is the complete solution, in prose. Never code.
For example, problem 1342D (*Multiple Testcases*, rated 1900) starts like this:
Hint 1. Consider a fixed size $$$i$$$. If you count how many of the given arrays have a size of at least $$$i$$$, let's call this count $$$g_i$$$, what is the absolute minimum number of testcases required just to accommodate these $$$g_i$$$ arrays...?
Hint 2. The requirement from each size $$$i$$$ provides a lower bound of $$$\lceil g_i / c_i \rceil$$$ on the total number of testcases. It turns out that the maximum of this value over all sizes is both necessary and sufficient...
Hints are only served for contests that are over, plus a 2-hour margin for system tests, so a live round is never spoiled.
See it working: LeekCF-Ratings already uses it
LeekCF-Ratings is a small extension for Codeforces practice, and it already uses the API today. It shows a problem's rating but hides the tags, so you can practice blind and reveal one tag at a time. Version 3 added Show Hints. Install it from the Chrome Web Store or Firefox Add-ons, or read the code on GitHub. It is just one client of the API; yours can be another.
Open your browser's DevTools, go to the Network tab, click Show Hints, and you will see the exact request and the full response.
Why Flash (the honest part)
This project has a budget of zero, so the hints are written by Google's Gemini Flash models on the free tier (98% of them by Flash-Lite). I chose them for cost reasons, not because they are the best option. Every hint is grounded in the official editorial, which helps a lot. I have not yet measured how often a hint is wrong compared with a stronger model, so treat them as a nudge and not as gospel.
The free quota also sets the speed: about 480 problems a day, which is why the backlog takes days.
Beta stats (November 2, 2026)
| Problems indexed | 10,763 |
| With hints | 6,833 (63% of all, 81% of the 8,475 that have an editorial) |
| Hints written | 25,788 (3.8 per problem on average) |
| Hints per problem | 2 → 1,193 · 3 → 1,657 · 4 → 1,484 · 5 → 2,499 |
| Contests covered | 1,176 (contest ids 14 to 2278) |
| Grounded in the official editorial | 6,833 of 6,833 |
| Written by | Gemini Flash family: 98% Flash-Lite, 2% Flash |
| Queued (editorial found) | 1,642, done around Nov 5 at ~480 a day |
| Parked (no editorial found yet) | 2,205, mostly older contests; hints written without an editorial are less reliable, so they wait |
| Skipped | 26 (22 are PDF-only statements; 4 the parser can't read) |
| Traffic so far | a few dozen API requests a day, so it is a real beta |
What's next
- Check a sample of hints against the editorials and publish the real numbers.
- Regenerate everything with a stronger model.
- Decide whether to write hints for problems that have no editorial at all.
Want to make it better? Message me
Everything is open source: the pipeline, the prompt and the validator. The weak link is the model, because free-tier Flash is what I can afford. A top model would write better hints, but redoing the whole set costs real money that I do not have.
**If you have paid access to Claude Opus or DeepSeek (credits, a key, a spare budget) and want to regenerate the hints with a stronger model, or you just want to help check hints for accuracy, send me a message on Codeforces or Github
Links and credits
- API and docs: https://leekcf-hinter-api.leekcf.workers.dev
- Code (Apache-2.0): https://github.com/ahmadsh2007/LeekCF-Hinter
- Extension: https://github.com/ahmadsh2007/LeekCF-Ratings, on the Chrome Web Store and Firefox Add-ons
- Problems and editorials belong to their authors and to Codeforces. Hinter serves only the hints, never a statement or an editorial, and every answer names its problem. It is free, has no ads, and is not affiliated with Codeforces.


















