Skip to content

Guides

How do I get a UFC fighter's record and career striking rates in Python?

Record by method, career rates per 15 minutes for striking, takedowns and control, Elo rating and peak, and recent fights, from one call.

Code verified October 10, 2026. One call to get_fighter, 5 credits.

The call

fighter_id comes from search_fighters.

import requests
import pandas as pd

API_KEY = "YOUR_API_KEY"

resp = requests.post(
    "https://mcp.fighterapi.com/v1/get_fighter",
    headers={"x-api-key": API_KEY},
    json={
        "fighter_id": "4350812",
    },
    timeout=60,
)
resp.raise_for_status()
data = resp.json()["data"]

f = data["fighter"]
print(f["name"], f["weight_class"], f["reach_in"], "in reach")
print(data["ufc_record"])
rates = pd.Series(data["career_rates"])
print(rates.round(2))
print("rating", data["rating"])
recent = pd.DataFrame(data["recent_fights"])
print(recent[["event_date", "fighter_b_name", "method_display", "end_round"]])

Replace YOUR_API_KEY with a key from your dashboard. Python needs requests and pandas (pip install requests pandas). JavaScript runs on Node 18 or newer, or in the browser.

What comes back

The data object of the response, trimmed to the first rows. Every field is real output from the run above.

{
  "fighter": {
    "fighter_id": "4350812",
    "name": "Ilia Topuria",
    "nickname": "El Matador",
    "height_in": 67,
    "reach_in": 69,
    "stance": "Orthodox",
    "weight_class": "Lightweight"
  },
  "ufc_record": {
    "wins": 9,
    "losses": 1,
    "draws": 0,
    "no_contests": 0,
    "wins_ko": 6,
    "wins_sub": 1,
    "wins_dec": 2,
    "losses_ko": 1,
    "losses_sub": 0,
    "losses_dec": 0
  },
  "career_rates": {
    "minutes_fought": 104,
    "sig_landed_per_15": 72.23,
    "sig_absorbed_per_15": 59.57,
    "sig_accuracy": 0.501,
    "sig_defense": 0.621,
    "td_per_15": 1.73,
    "td_accuracy": 0.571,
    "td_defense": 0.952,
    "sub_attempts_per_15": 0.86,
    "control_share": 0.205,
    "knockdowns": 8
  },
  "rating": {
    "current": 1655,
    "peak": 1670
  },
  "recent_fights": [
    {
      "event_name": "UFC Freedom 250: Topuria vs. Gaethje",
      "event_date": "2026-06-14",
      "fighter_b_name": "Justin Gaethje",
      "winner": "3022345",
      "method_display": "KO/TKO",
      "end_round": 4
    },
    {
      "event_name": "UFC 317: Topuria vs. Oliveira",
      "event_date": "2025-06-28",
      "fighter_b_name": "Charles Oliveira",
      "winner": "4350812",
      "method_display": "KO/TKO",
      "end_round": 1
    },
    "...3 more"
  ]
}

What to do next

  • get_fighter_fights (5 credits). Every UFC fight, not just the recent few, with stats and ratings.
  • get_leaders (5 credits). Rank fighters on any of these rates, by weight class.

More guides

Start with 500 free credits

No card. REST or MCP.