Team logos, wordmarks, headshots and colors for Python plots and tables, from the SportsDataverse logo archive. It
resolves team abbreviations, names and provider ids across 28 leagues and picks the right era's mark for a season. Colors
and logos work with any library through palette(), team_colors(), logo_url() and logo_image(), and the
add_logos(), add_wordmarks() and add_headshots() adapters draw them on matplotlib, plotnine, plotly, altair, bokeh,
holoviews, great_tables, folium and pygal plots, tables and maps. The Python counterpart to sdvplotR. See
CHANGELOG.
pip install git+https://github.com/sportsdataverse/sdvplot
# or
uv add git+https://github.com/sportsdataverse/sdvplotsdvplot is not on PyPI yet, so install it from GitHub. Plotting libraries are optional extras, for example
pip install "sdvplot[mpl] @ git+https://github.com/sportsdataverse/sdvplot". Each extra adds the libraries for one feature: [svg] lets logo_image()
rasterize SVG marks. With [mpl], [plotnine], [plotly], [altair], [bokeh], [holoviews], [tables],
[folium] or [pygal], add_logos(), add_wordmarks() and add_headshots() draw on that library's plots, tables and
maps; axis_logos() works on matplotlib, seaborn, plotnine, Plotly and Altair. [surfaces] is for surface(), and
[reactable] and [plottable] add column helpers (sdvplot.reactable, sdvplot.plottable).
| Extra | Adds |
|---|---|
[mpl] |
matplotlib |
[plotnine] |
plotnine |
[plotly] |
plotly |
[altair] |
altair |
[bokeh] |
bokeh |
[holoviews] |
holoviews |
[tables] |
great_tables |
[reactable] |
reactable (reactable-py) |
[folium] |
folium |
[svg] |
resvg-py, for SVG marks |
[surfaces] |
sportypy and mplsoccer |
[plottable] |
plottable |
[all] |
everything above |
import sdvplot
sdvplot.resolve(["LV", "OAK", "Las Vegas Raiders"], "nfl") # ['13', '13', '13']
sdvplot.palette("nfl", teams=["LV", "KC"]) # {'LV': '#000000', 'KC': '#e31837'}
sdvplot.logo_url("OAK", "nfl", season=2010) # the Oakland-era mark
img = sdvplot.logo_image("LV", "nfl", size=128) # a PIL imageColors work in any library that takes a {value: color} mapping, for example seaborn:
sns.barplot(data=df, x="team", y="epa", hue="team", palette=sdvplot.palette("nfl", teams=df["team"])).
Colors marked color_source="fallback" are placeholders, not team colors.
SDVPLOT_CACHE_DIR: cache root.SDVPLOT_CACHE_TTL: cache lifetime in days (default 7).SDVPLOT_LIVE_TESTS=1: enable the network tests.
- Docs site with concepts, tutorials and the API reference.
- Changelog.
- Contributing.
Team names, logos, wordmarks and player headshots are trademarks or copyrighted works of their respective leagues, teams, schools and other rights holders. sdvplot is not affiliated with, sponsored by or endorsed by any of them, and using sdvplot to draw a mark grants no right to use it. The package ships no logo files: the wheel carries only an index of team names, ids and colors, and marks are fetched at runtime from the SportsDataverse logo archive. Use of any mark in your own work is governed by that owner's terms, and following them is your responsibility. The MIT license covers the sdvplot code only; team data belongs to its respective owners and sources.
- sdvplotR: the R package this one mirrors.
- sdv-py: SportsDataverse data for Python.
- sportypy: sports surfaces for Python plots.
To cite sdvplot in publications, use:
BibTex Citation
@misc{gilani_2026_sdvplot,
author = {Gilani, Saiem},
title = {sdvplot: Team logos, wordmarks, headshots and colors for Python plots and tables},
url = {https://sdvplot.sportsdataverse.org},
year = {2026}
}