Skip to main content

NFL — PFF Premium Stats -- LEGACY (premium.pff.com, cookie auth; use the PFF Developer API) — Other

pff_leagues​

LEGACY (premium.pff.com cookie auth; prefer the pff_api_* Developer API wrappers). Leagues + seasons + week groups (bootstrap)

Endpoint URL: GET https://premium.pff.com/api/v1/leagues

Valid URL: https://premium.pff.com/api/v1/leagues

API ParameterPythonPatternRequiredNullableDescription

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
abbreviationStringLeague abbreviation as the source lists it (e.g. NFL).
default_seasonFloat64Season the source API currently treats as the default for this league.
default_weekFloat64Week number the source API currently treats as the default for this league.
default_week_groupStringIdentifier of the week grouping (e.g., regular season or postseason phase) currently set as the league default.
idFloat64Numeric league id from the source API (PFF: 1 = NFL).
nameStringLeague display name as the source lists it (PFF: 'Pro Football').
seasonsListNested list (stringified) of the seasons the source publishes for the league.
slugStringURL slug of the league on premium.pff.com (e.g. nfl).
week_groupsListNested list of week-group objects (phase label and week span) defined for the league.
weeksListNested list of week objects available for the league.

return_parsed=False — the raw JSON Dict payload, unparsed.

Raises​

ExceptionDescription
NoDataErrorThe host answered 404 -- the requested resource does not exist.
ValueErrorThe host answered 400 / 422 -- the request is wrong; retrying cannot help.
AssetFetchErrorThe fetch failed (a non-2xx answer or a connection failure after retries, e.g. 401/403/429/5xx, or an empty or unreadable 200 body) -- the answer is unknown, not empty.

Example​

pff_leagues()

pff_teams​

LEGACY (premium.pff.com cookie auth; prefer the pff_api_* Developer API wrappers). Teams / franchise groups + games for a league-season

Endpoint URL: GET https://premium.pff.com/api/v1/teams

Valid URL: https://premium.pff.com/api/v1/teams

API ParameterPythonPatternRequiredNullableDescription
leagueleagueYLeague slug (nfl/ncaa/aaf/ufl); pre-bound by the per-league shim modules.
seasonseasonYSeason (starting year).

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
heirarchyListNested hierarchy of franchise groupings as returned by the PFF API; the field name's spelling follows the source.
idFloat64PFF id of the conference, division or tier group (e.g. 1 = AFC, 2 = AFC East).
nameStringGroup name (e.g. "AFC", "AFC East"; NCAA groups such as "FBS" or "The American").
slugStringURL-style slug of the group (e.g. "afc-east").

return_parsed=False — the raw JSON Dict payload, unparsed.

Raises​

ExceptionDescription
NoDataErrorThe host answered 404 -- the requested resource does not exist.
ValueErrorThe host answered 400 / 422 -- the request is wrong; retrying cannot help.
AssetFetchErrorThe fetch failed (a non-2xx answer or a connection failure after retries, e.g. 401/403/429/5xx, or an empty or unreadable 200 body) -- the answer is unknown, not empty.

Example​

pff_teams()

pff_teams_overview​

LEGACY (premium.pff.com cookie auth; prefer the pff_api_* Developer API wrappers). Team overview table (By Team landing)

Endpoint URL: GET https://premium.pff.com/api/v1/teams/overview

Valid URL: https://premium.pff.com/api/v1/teams/overview

API ParameterPythonPatternRequiredNullableDescription
leagueleagueYLeague slug (nfl/ncaa/aaf/ufl); pre-bound by the per-league shim modules.
seasonseasonYSeason (starting year).
weekweekYWeek or week-group key (e.g. 'REG', a week number, or a range).

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
abbreviationStringTeam abbreviation.
franchise_idFloat64PFF franchise (team) id (integer join key).
grades_coverage_defenseFloat64PFF team coverage grade (0-100).
grades_defenseFloat64PFF team defense grade (0-100).
grades_misc_stFloat64Team-level PFF miscellaneous special-teams grade, 0-100.
grades_offenseFloat64PFF team offense grade (0-100).
grades_overallFloat64Team-level PFF overall grade, 0-100.
grades_passFloat64Team-level PFF passing grade, 0-100.
grades_pass_blockFloat64Team-level PFF pass-blocking grade, 0-100.
grades_pass_routeFloat64Team-level PFF receiving (route-running) grade, 0-100.
grades_pass_rush_defenseFloat64Team-level PFF pass-rush grade, 0-100.
grades_runFloat64Team-level PFF rushing grade, 0-100.
grades_run_blockFloat64Team-level PFF run-blocking grade, 0-100.
grades_run_defenseFloat64Team-level PFF run-defense grade, 0-100.
grades_tackleFloat64Team-level PFF tackling grade, 0-100.
lossesFloat64Games the team lost over the covered span.
nameStringFull team name (e.g. "Arizona Cardinals").
points_allowedFloat64Total points allowed by the team over the covered span.
points_scoredFloat64Total points scored by the team over the covered span.
tiesFloat64Games the team tied over the covered span.
winsFloat64Games the team won over the covered span.

return_parsed=False — the raw JSON Dict payload, unparsed.

Raises​

ExceptionDescription
NoDataErrorThe host answered 404 -- the requested resource does not exist.
ValueErrorThe host answered 400 / 422 -- the request is wrong; retrying cannot help.
AssetFetchErrorThe fetch failed (a non-2xx answer or a connection failure after retries, e.g. 401/403/429/5xx, or an empty or unreadable 200 body) -- the answer is unknown, not empty.

Example​

pff_teams_overview()

pff_games​

LEGACY (premium.pff.com cookie auth; prefer the pff_api_* Developer API wrappers). Games list for league-season(-week)

Endpoint URL: GET https://premium.pff.com/api/v1/games

Valid URL: https://premium.pff.com/api/v1/games

API ParameterPythonPatternRequiredNullableDescription
leagueleagueYLeague slug (nfl/ncaa/aaf/ufl); pre-bound by the per-league shim modules.
seasonseasonYSeason (starting year).
weekweekYSingle week number.

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
away_franchise_idFloat64PFF franchise id of the away team.
away_teamListAway team object (JSON-stringified in the tidy frame).
has_statsBooleanWhether PFF has published stats for the game.
home_franchise_idFloat64PFF franchise id of the home team.
home_teamListHome team object (JSON-stringified in the tidy frame).
idFloat64PFF game id (integer join key).
leagueListNested league object of the game (stringified) with the PFF league id, name and abbreviation (e.g. NFL).
league_idFloat64PFF league id (integer).
lock_statusStringData lock/publish status for the game.
scoreListNested final-score object of the game (stringified) with away_team and home_team points.
seasonFloat64Season (starting year) of the game.
stadium_idFloat64PFF stadium identifier for the game venue.
startStringKickoff timestamp (ISO 8601 string).
weekFloat64Week number of the game.

return_parsed=False — the raw JSON Dict payload, unparsed.

Raises​

ExceptionDescription
NoDataErrorThe host answered 404 -- the requested resource does not exist.
ValueErrorThe host answered 400 / 422 -- the request is wrong; retrying cannot help.
AssetFetchErrorThe fetch failed (a non-2xx answer or a connection failure after retries, e.g. 401/403/429/5xx, or an empty or unreadable 200 body) -- the answer is unknown, not empty.

Example​

pff_games()