Public APIs
Codeforces favicon

Codeforces

Programming

Get access to Codeforces data.

Codeforces's website screenshot

About Codeforces

The Codeforces API provides programmatic, read-only access to data from the Codeforces competitive programming platform in JSON format. Requests are made over HTTP to method-specific endpoints, with methods covering blog entries and comments, contests (hacks, list, rating changes, standings, status), groups, problem sets, recent actions, system status, and user data (blog entries, friends, info, rated list, rating, status). Responses include a status field and either a result object on success or a comment explaining failure.

Most methods can be called anonymously and return only public data. Access to private data, such as hacks during a contest, requires an API key and secret generated from a user's Codeforces settings page, combined with a time parameter and an SHA-512-based signature (apiSig) computed over the request parameters. Requests are rate-limited to one per two seconds, and results can be returned in English or Russian via a lang parameter. JSONP is supported by adding a jsonp parameter, wrapping the response in a callback function.

This API is intended for developers building tools, statistics dashboards, or integrations that consume competitive programming data such as contest results, problem sets, user ratings, and submission history from Codeforces.

Key features

  • Access Codeforces contest, problem, user, and rating data via JSON-formatted HTTP requests
  • Query methods for contests, problem sets, user info/status/ratings, blog entries, and comments
  • Anonymous access to public data, with API key authentication for private data like contest hacks
  • Optional JSONP support for returning results as a JavaScript function call
  • Language selection between English and Russian via a lang parameter

Frequently asked questions

Is the Codeforces API free to use?

The documentation does not mention any cost; anonymous requests to public data require no payment or key.

Is there a rate limit?

Yes, the API may be requested at most once every two seconds, and exceeding this returns a FAILED status with a 'Call limit exceeded' comment.

How do I authenticate for private data?

You generate an API key and secret on the Codeforces settings page, then include apiKey, time, and an apiSig SHA-512 signature in your requests.

What data format does the API return?

The API returns machine-readable JSON objects with status, comment, and result fields, and also supports JSONP for JavaScript callback responses.

Who is this API for?

It is for developers who want programmatic access to Codeforces data such as contests, problems, users, ratings, and blog entries.

Advertise here

Featured products

  • SerpApi - Search API favicon
  • Screenshot Scout favicon
  • TalorData favicon
  • CoreClaw favicon

Show your product to thousands of developers

· 100k monthly pageviews
· 7k newsletter subscribers

Advertise your product