# UFC Fighter Profiles & Fight History Extractor (`scrapermaster/ufc-fighter-profiles-history`) Actor

Get UFC fighter profiles with physical attributes, career totals and optional fight-by-fight history including striking and grappling numbers. Search by name, letter or URL.

- **URL**: https://apify.com/scrapermaster/ufc-fighter-profiles-history.md
- **Developed by:** [Scraper Master](https://apify.com/scrapermaster) (community)
- **Categories:** Sports, News, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $16.50 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## UFC Fighter Profiles & Fight History Extractor

Build a fighter database in minutes. Each fighter is returned as one record, with the complete bout history attached if you want it.

### What you get

**Profile**: name, nickname, record, height, weight, reach, stance and date of birth.
**Career totals**: striking and grappling averages and accuracy.
**Fight history (optional)**: opponent, event, result, method, round and time, plus knockdowns, strikes and takedowns for each bout.

### Three ways to choose fighters

1. **Search** - a name or nickname in **Fighter or event name** (`mcgregor`, `silva`, `spider`).
2. **Direct links** - paste fighter page URLs into **UFCStats URLs**.
3. **Browse the directory** - leave both empty and optionally restrict by **Last-name letters**.

### Filters

`stance` (Orthodox, Southpaw, Switch...), `minWins`, `minLosses`. Filters are applied to the directory list, so they save requests.

#### Example input

```json
{
  "searchQuery": "silva",
  "includeFightHistory": true,
  "maxItems": 20
}
```

### Notes

- Turn **Include fight history** off for a fast, cheap profile-only export.
- A targeted run (search or URLs) returns only what it matched and is never padded.
- Proxy settings default to a datacenter proxy.

### Support

Open an issue with the fighter name or URL and the run ID.

# Actor input Schema

## `maxItems` (type: `integer`):

How many fighter records to collect per run. A targeted run is never padded up to this number: it is a cap, not a target.

## `startUrls` (type: `array`):

Specific fighter profile URLs to scrape, e.g. https://ufcstats.com/fighter-details/f4c49976c75c5ab2. When set, ONLY these fighters are scraped: the search and the alphabet walk stay off, so the run returns at most as many rows as URLs you give. Event and fight URLs are not fighter profiles and are reported as skipped.

## `searchQuery` (type: `string`):

Search UFCStats by first name, last name or nickname, e.g. 'mcgregor', 'silva', 'spider'. UFCStats matches one name at a time, so a full name such as 'Jon Jones' is searched part by part and only the fighters matching every part are kept. When set, the alphabet walk stays off: a search that matches nothing returns zero rows and says so rather than returning other fighters.

## `letters` (type: `array`):

Restrict the alphabet walk to these starting letters of the fighter last name. Leave empty to walk A through Z. Ignored when start URLs or a search term are given.

## `stance` (type: `string`):

Only return fighters with this stance. Leave empty for all stances. Applied from the directory listing where possible, so non-matching fighters are not fetched or charged.

## `minWins` (type: `integer`):

Only include fighters with at least this many career wins. Applied from the directory listing where possible, so non-matching fighters are not fetched or charged.

## `minLosses` (type: `integer`):

Only include fighters with at least this many career losses. Applied from the directory listing where possible, so non-matching fighters are not fetched or charged.

## `includeFightHistory` (type: `boolean`):

Include the full per-fight history table (opponent, event, method, round, time, KDs, strikes, takedowns, submissions) on each fighter record.

## `proxyConfiguration` (type: `object`):

Proxy configuration for requests. Defaults to Apify datacenter proxy, which works well for ufcstats.com. The scraper rotates proxy sessions and falls back to a direct connection automatically if the proxy fails.

## Actor input object example

```json
{
  "maxItems": 10,
  "stance": "",
  "includeFightHistory": true,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "maxItems": 10,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapermaster/ufc-fighter-profiles-history").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "maxItems": 10,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("scrapermaster/ufc-fighter-profiles-history").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "maxItems": 10,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call scrapermaster/ufc-fighter-profiles-history --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scrapermaster/ufc-fighter-profiles-history"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/DqaCNaOG4ufcRBLEi/builds/RwdYNqilLVJu6pGDP/openapi.json
