Make Your Own Federation

Open-source multi-sport dynasty fantasy league dashboard

Everything you see on this site — federation standings, per-league dashboards, playoff brackets, team profiles, the member portal with trades and voting — is available as a free, open-source template you can customize for your own league.

Get the Template

Clone the repo and follow the setup guide below to get your federation running.

View on GitHub

What You Get

Federation Standings

Combined rankings across NFL, NBA, NHL, and MLB with federation points, race chart, and tiebreaker resolution.

League Dashboards

Per-league standings, rosters sorted by position, matchup scores, and interactive 6-team playoff brackets.

Team Profiles

Complete rosters, head-to-head records, season schedule, and draft capital tracker across 8 future seasons.

Trade Portal

Submit 2–4 team trades with player/pick/FAAB dropdowns, counter-party acceptance, and Commission review.

Governance

Proposals, voting with configurable thresholds, commissioner memos, and a searchable constitution page.

Power Rankings

6-component weighted algorithm with z-score normalization for cross-sport comparison.

Auto Scraping

Python scraper pulls from Fantrax every 30 minutes. Cron job keeps your data fresh automatically.

Notifications

Email (Gmail SMTP), Telegram bot, and optional iMessage integration for trade announcements.

Prerequisites

Setup Guide

1 Clone the Repository

git clone https://github.com/gabrielmeir53/federation-fantasy-dashboard.git
cd federation-fantasy-dashboard

2 Configure Your Leagues

Copy .env.example to .env and fill in your Fantrax league IDs. You can find these in the URL when you visit your league on Fantrax.

cp .env.example .env
# Edit .env with your league IDs, Google Sheet IDs, etc.

3 Customize Teams

In the scraper config, update FED_TEAMS with your 12 team names, abbreviations, owner names, colors, and logos. Update team_name() in portal/includes/functions.php to match.

4 Set Up the Database

Create a MySQL database and run the schema files in order:

mysql -u your_user -p your_database < portal/setup/schema.sql
mysql -u your_user -p your_database < portal/setup/migration_trades.sql
php portal/setup/seed.php

Update portal/includes/config.php with your database credentials, domain, and email settings.

5 Run the Scraper

pip install -r requirements.txt
python scrape_fantrax.py --verbose

This fetches data from Fantrax and generates JSON files. Open site/index.html in your browser to see the dashboard.

6 Deploy

Upload the site/ and portal/ directories to your web server. The deploy/ directory contains example configs for cPanel (htaccess, cron wrapper, manual trigger endpoint).

7 Set Up Auto-Scraping

Add a cron job to run the scraper every 30 minutes:

*/30 * * * * bash /path/to/deploy/run_scraper.sh

8 Optional: Notifications

Set up a Telegram bot for trade notifications, configure Gmail SMTP for email alerts, or use the iMessage polling script on a Mac for group chat announcements. See the README for details.

Tech Stack

No frameworks, no build step, no npm. The entire project runs on:

Ready to Build?

The full source code, documentation, and example data are on GitHub.

Get the Code Read the Docs

License

This project is released under the MIT License with Attribution. You're free to use, modify, and distribute it — just include a visible link to ysffantasy.com in your deployment. See the full license for details.

Questions?

If you need help setting up your federation or run into issues, reach out at info@ysffantasy.com.