WOMBO COMBO
Stats & Analytics Tools

How the League of Legends API Works: The Tech Behind OP.GG and U.GG

Every time you look up a summoner on OP.GG or U.GG, that data comes from Riot's official API. This article explains how the API works, what data it exposes, and the technical architecture behind the platforms you use every day.

8 sections~9 min readPublished Dec 9, 2024Last updated Apr 16, 2026

Key takeaways

  • What Is the Riot Games API and How Does Access Work
  • Summoner and Account Endpoints: How Profile Lookups Work
  • Match History API: How Platforms Store and Query Past Games
  • How Aggregate Statistics Are Built From Millions of Games
  • Live Game API: How Real-Time Match Data Is Exposed

01

What Is the Riot Games API and How Does Access Work

Riot Games provides a public REST API that allows developers to access League of Legends game data programmatically. The API has been available since 2013 and has evolved substantially over the years, expanding coverage to include Teamfight Tactics, VALORANT, Legends of Runeterra, and other Riot titles. The League of Legends component of the API covers summoner profiles, match history, champion mastery, ranked standings, live game data, and static data like champion and item information.

Access to the Riot API requires an API key, which developers obtain by registering an application through Riot's developer portal at developer.riotgames.com. Development keys are free but rate-limited to 100 requests per two minutes, which is sufficient for personal projects but inadequate for production services that need to handle thousands of simultaneous users. Production-grade applications like OP.GG and U.GG apply for elevated API access — called production keys — which come with higher rate limits commensurate with the platform's scale.

Riot's API uses standard REST conventions — you make HTTP GET requests to endpoints with specific parameters, and the server returns JSON-formatted data. The base URL includes the region — for example, na1.api.riotgames.com for North America — and the endpoint path specifies what data you are requesting. Authentication uses the API key passed as a query parameter or request header. Any developer comfortable with HTTP requests and JSON parsing can start working with Riot data within an hour of reading the documentation.

02

Summoner and Account Endpoints: How Profile Lookups Work

When you type a summoner name into OP.GG and hit search, the platform makes a request to the Riot API's summoner-by-name endpoint, passing the summoner name as a parameter and receiving back a JSON object containing the summoner's unique ID, account ID, PUUID, profile icon ID, and summoner level. The PUUID — Player Universally Unique Identifier — is the most important of these values because it is region-agnostic and used to look up match history across all servers.

A significant API change in 2023 shifted the primary identifier from summoner names to Riot IDs — the Game Name and Tag Line format like PlayerName#NA1. This change was necessary because summoner names are unique only within a region, while Riot IDs are globally unique. Third-party platforms had to update their search functionality to accept both formats during the transition period, which is why some sites now show both the old summoner name and the Riot ID format on profile pages.

Once a platform has the summoner's PUUID, it can look up ranked data through the league entries endpoint, which returns the player's current tier, division, LP, wins, losses, and hot streak status for each queue type. This is the data that populates the rank badge and win rate on sites like OP.GG. The ranked data updates in near real-time — typically within a few minutes of a game ending — because the endpoint queries Riot's live ranked database.

03

Match History API: How Platforms Store and Query Past Games

Match history is retrieved through the match-v5 endpoint, which returns a list of match IDs for a given PUUID. The platform then fetches individual match details by match ID, receiving a large JSON object containing every statistic tracked during that game — each player's items, runes, KDA, CS, damage dealt, gold earned, ward stats, and dozens of other data points. A single match detail response can be several hundred kilobytes of data.

The rate limits on match history retrieval create a significant engineering constraint for third-party platforms. Fetching 100 recent games for a single summoner requires 101 API calls — one to get the list of match IDs, then one per match to get the details. With production rate limits, this can take several seconds. OP.GG and U.GG solve this problem by proactively caching match data for frequently-viewed summoners — they fetch and store your match history in their own database, so subsequent profile views serve data from cache rather than making live API calls.

This caching architecture explains why you sometimes need to manually update your profile on these sites after recent games. If the platform's cached version of your profile is 20 games old and you just finished 5 more games, clicking the Update button triggers a fresh API call to fetch the latest match IDs, then fetches only the new matches that are not already in the cache. Platforms refresh popular profiles automatically on a schedule, but less-active summoners may have stale cached data until manually updated.

04

How Aggregate Statistics Are Built From Millions of Games

Computing a champion's aggregate win rate requires processing match data from potentially millions of games. No platform queries the Riot API to compute these statistics in real time — the API does not support bulk queries that would make that feasible. Instead, platforms like OP.GG and U.GG run continuous background pipelines that fetch new match data as games are completed, store it in their own databases, and periodically recompute aggregate statistics across their stored dataset.

The data pipeline typically works as follows: the platform maintains a queue of recently-active summoners whose match history needs updating. Background workers pull from this queue, fetch new match IDs via the API, retrieve full match details for each new match, and insert the parsed data into a relational or columnar database optimized for analytics queries. Separate aggregation jobs run periodically — hourly or multiple times daily — to recompute champion statistics, tier lists, and other derived metrics from the accumulated match data.

The database schema for this kind of system is designed for analytical workloads. Storing every statistic for every participant in every match produces a very wide fact table — potentially 100 or more columns per row, with one row per player per game. Analytics queries like computing the win rate of Ahri mid lane in Platinum-plus games on the current patch run as SQL aggregations over this table, grouping and filtering across potentially hundreds of millions of rows. Columnar storage formats handle this efficiently.

05

Live Game API: How Real-Time Match Data Is Exposed

The Riot API provides a spectator endpoint that returns information about a game currently in progress for a specified summoner. This endpoint returns the champion picks, summoner spells, rune selections, and team composition for the ongoing match. Critically, it does not return in-game real-time data like current health, ability cooldowns, or live item purchases — just the pre-game setup information that was locked in before the match started.

Third-party platforms use this endpoint to power the Live Game feature. When you view a summoner's profile on OP.GG and click Live Game, OP.GG makes a request to the spectator endpoint to check if that summoner is in an active game. If so, it returns the team compositions and then enriches that data by looking up each participant's profile from its own cache — adding the each player's rank history, champion performance, and recent form that the spectator endpoint itself does not provide.

The spectator endpoint also returns a gameId and an encryption key that, combined with the appropriate game client, can be used to connect a spectator client to a live game for real-time viewing. This is the technical mechanism behind the in-client spectating feature. Third-party developers can build external spectating tools using this data, though the use cases are primarily coaching and content creation rather than gameplay analytics.

06

Static Data: Champions, Items, Runes, and Data Dragon

Static game data — champion names, abilities, item descriptions, rune trees, summoner spells — is served separately from the live API through a system called Data Dragon, which is a versioned static file repository maintained by Riot. Data Dragon releases new versions with each League of Legends patch and contains JSON files with all champion statistics, item data, and rune configurations for that patch version. Third-party platforms download and cache these static files locally to avoid repeatedly fetching them from Riot's servers.

When a new patch deploys, platforms must update their local Data Dragon cache to reflect the new champion stats, item changes, and rune modifications. This update process is typically automated but requires engineering attention when major changes occur — for example, when new champions are added, when the item system receives a large overhaul, or when rune systems are restructured. The 2022 item overhaul required significant engineering work at every major platform to update their data models.

Champion assets — splash art, ability icons, champion portraits — are also served through Data Dragon as versioned image files. When OP.GG or U.GG displays a champion icon on your profile or in tier list views, they are serving that image from either their own CDN-cached copy of Data Dragon assets or directly from Riot's CDN, depending on their architecture. Using CDN caching for static assets is standard practice to reduce latency and Riot's bandwidth costs for widely-requested assets.

07

Rate Limits and the Engineering Challenges at Scale

Rate limits are the most significant technical constraint third-party platforms face when working with the Riot API. Production API keys receive rate limits that allow thousands of requests per minute, but platforms like OP.GG serve millions of users per day and must track data for potentially hundreds of millions of summoners globally. Efficient cache management, intelligent background refresh scheduling, and priority queuing for frequently-accessed summoners are all necessary to operate within rate limits at that scale.

Data freshness is a constant tension with rate limit constraints. Users want their profile data to reflect games played minutes ago, but updating profiles for every active summoner within minutes of each game ending requires a very high API request volume. Platforms solve this by tiering update frequency — high-activity summoners who view their profile frequently are updated more often than dormant accounts that nobody has searched in weeks. Popular summoners, streamers, and professional players often receive near-real-time updates because demand for their data is high enough to justify the API quota.

The Riot API also imposes regional routing requirements — you must query region-specific endpoints for the appropriate server. A North American summoner must be looked up through the NA1 endpoint, not the EUW1 endpoint. For global platforms that cover all regions, this means maintaining API integrations across a dozen regional endpoints and routing each user query to the correct regional server. Handling summoner name transfers, region migrations, and the new Riot ID system across regions added additional complexity to these routing requirements.

08

Building Your Own Tools on the Riot API

The Riot API is fully accessible to individual developers and provides enough data to build meaningful personal analytics tools with modest programming experience. A developer who knows Python or JavaScript can build a script that fetches their own match history, computes personal statistics across their last 100 games, and outputs a custom performance report in an afternoon. The Riot developer portal provides comprehensive documentation, code samples, and a testing sandbox.

Community libraries simplify API integration significantly. Python libraries like Cassiopeia and Pulsefire handle authentication, rate limit management, caching, and data transformation, allowing developers to focus on analysis logic rather than HTTP request plumbing. JavaScript libraries serve the same purpose for Node.js developers. Using a community library reduces the time required to get a functional API integration from hours to minutes.

The terms of service for Riot API usage permit non-commercial applications freely, with requirements around product registration and policy compliance for public-facing tools. Commercial applications that monetize their API-based products require explicit approval from Riot and must go through a review process. Riot has been generally supportive of the third-party ecosystem and the platforms like OP.GG and U.GG that enrich the player experience, but they reserve the right to revoke access from tools that violate their policies or provide unfair gameplay advantages.

Next step

Run a live lookup on the homepage

Take the article into practice. Search a summoner, inspect recent matches, and use the same stats directly in Wombo Combo.