Scrape all available UFC events data, fights stats, and fighter details from ufcstats.com and save in CSV format.
pip install -r requirements.txtData for all events, fights, and fighters have been scraped and saved as the following data files:
- ufc_event_details
- ufc_fight_details.csv
- ufc_fight_results.csv
- ufc_fight_stats.csv
- ufc_fighter_details.csv
- ufc_fighter_tott.csv
To download the CSV files without running any code, click: Download stats
-
To scrape the all data for events and fights including results and stats:
scrape_ufc_stats_all_historical_data.ipynb. -
To scrape the data for all fighters including inculding tale of the tape:
py get_all_fighters_and_tott.py
Note: these will each take a few hours to complete.
- Once you have the data you can run:
py update_all_ufc_stats.pyto get the latest updates only.
- The notebook
scrape_ufc_stats_working_example.ipynbcan be used for testing or debugging. The code here is broken down into sections which can be executed to scrape single data points, e.g. scraping stats for one fight only.
Find the next upcoming UFC event, and extract details about every fight scheduled for that event.
Saved to a CSV file named next_event.csv.
from the root directory:
cd next_event/next_eventthen:
py -m scrapy crawl eventFiles dated June 22, 2025 and newer have been modified from the original https://github.com/Greco1899/scrape_ufc_stats