Install & Compatibility
Where this runs
tested against v3.8.3 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 1.488s · 447MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 20.6s · import 1.372s · 426MB
452MB installed
● package 452MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to import FastF1, enable local caching for performance, load a specific Formula 1 race session, and then access basic lap data. The `session.load()` call fetches the data from the API, and caching ensures subsequent calls are faster. It's recommended to load only necessary data (e.g., `telemetry=False` if not needed) to speed up the process.
import fastf1
import os
# Enable caching to a local directory (e.g., 'cache')
cache_dir = os.path.join(os.getcwd(), 'fastf1_cache')
os.makedirs(cache_dir, exist_ok=True)
fastf1.Cache.enable_cache(cache_dir)
# Load a race session (e.g., 2023 Austrian Grand Prix, Race session)
session = fastf1.get_session(2023, 'Austria', 'R')
session.load(telemetry=False, weather=False)
# Print basic session information and first few laps
print(f"Loaded session: {session.event.EventName} - {session.name}")
print(f"Number of laps: {len(session.laps)}")
print("First 5 laps:\n", session.laps.head())
Debug
Known issues
gotchaAlways enable caching. FastF1 heavily relies on caching to store downloaded data locally. Without it, you will experience significantly slower data loading times due to repeated API requests, and you risk hitting API rate limits.fixCall `fastf1.Cache.enable_cache('/path/to/cache_dir')` immediately after importing fastf1 and before making any data requests. affects: All versions
breakingFastF1 requires Python 3.10 or higher. Older Python versions (e.g., 3.8 or 3.9) are not supported and may lead to installation or runtime errors.fixUpgrade your Python environment to version 3.10 or newer.
affects: <3.10
gotchaData availability post-race can vary. While results and lap timing might appear sooner, full telemetry data often takes 30-120 minutes after the checkered flag to become available. Automated data ingestion pipelines should account for this delay or potential partial data.fixImplement retry logic and checks for data completeness, especially for telemetry. Schedule data fetching tasks with a reasonable delay (e.g., 1-2 hours) after a session concludes.
affects: All versions
deprecatedFastF1 has transitioned its historical data access from the Ergast API to the jolpica-f1 API. While FastF1 handles this internally, users relying on older `f1dataR` integrations or directly interacting with Ergast might face issues as Ergast becomes defunct.fixEnsure you are using a recent version of FastF1 (3.1.0 or newer) which seamlessly integrates with jolpica-f1.
affects: <3.1.0
gotchaData fields may change or be unavailable with new F1 regulations. Specifically, for the 2026 regulations, new data fields related to power unit and ERS deployment might not be exposed, and existing ERS charge/deploy data may not be available through the official feeds.fixMonitor FastF1 releases and official documentation for updates regarding new data fields or changes in data availability following regulation shifts. Validate data schema when working with new seasons.
affects: Future seasons (2026+)
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'fastf1'
The fastf1 package has not been installed in your Python environment or the environment where your script is being run.
fixInstall the package using pip: `pip install fastf1` or `python -m pip install fastf1`.
DataNotLoadedError: The data you are trying to access has not been loaded yet. See `Session.load`
You are attempting to access data attributes (like laps, car_data, etc.) from a FastF1 `Session` object before calling the `session.load()` method to fetch the data from the API.
fixCall `session.load()` before accessing any data attributes, for example: `session = fastf1.get_session(2023, 'Monaco', 'Q')` then `session.load()`.
ValueError: Failed to load any schedule data.
FastF1 failed to retrieve the season schedule from its backend APIs (F1 API and Ergast API), often due to network connectivity issues, API rate limits, or a temporary problem with the data sources.
fixCheck your internet connection, ensure you're not hitting API rate limits, or try enabling/clearing the FastF1 cache using `fastf1.Cache.enable_cache('/path/to/cache_directory')` and potentially deleting existing cache files. Sometimes waiting and retrying also resolves the issue. AttributeError: 'Weekend' object has no attribute 'load_laps'
This error occurs when you try to call `load_laps()` directly on a `Weekend` object. In FastF1, `load_laps()` (or simply `load()`) should be called on a `Session` object, which represents a specific practice, qualifying, or race session within a weekend.
fixFirst get a specific session from the `Weekend` event, then call `load()` on the session. For example: `session = fastf1.get_session(2021, 'Qatar', 'P1')` then `session.load(laps=True)` or `session.load()`.
logger WARNING Failed to load telemetry data!
This warning indicates that FastF1 encountered an issue while trying to fetch telemetry data (e.g., car data, position data) for a session. This can happen if the data is not available on the F1 API backend yet (especially for very recent sessions), due to temporary network problems, or if there's no telemetry for the specific session type.
fixEnsure `session.load(telemetry=True)` is explicitly called if you need telemetry. Check if the session is recent and if the data is expected to be available. Verify your internet connection and try running the script again later. For some older sessions, detailed telemetry might simply not exist.
Upgrade
Version history
3.8.3latest on PyPI · released Apr 29, 2026
Audit
Dependencies
pandasrequiredData is returned as extended Pandas DataFrames for easy manipulation and analysis.
matplotlibrequiredIntegrated for data visualization and plotting.
numpyrequiredUnderlying numerical operations.