# Nigeria Power Data
Production-grade Flask energy intelligence dashboard for Nigeria's power grid at
`
nigeriapowerdata.com`.
The platform collects public NISO/NIGGRID readings, stores historical grid
records in PostgreSQL, and turns generation, GenCo, DisCo, and distribution
signals into operational analytics.
## Core Features
- Real-time NISO/NIGGRID data scraping with retry, timeout, and stale fallback handling.
- PostgreSQL persistence through SQLAlchemy, with SQLite fallback for local development.
- Flask-Migrate/Alembic migration support.
- Automatic startup migrations for Render free-tier deployments without shell access.
- APScheduler data collection every 30 minutes with a single protected job id.
- Historical generation, DisCo allocation, GenCo performance, analytics snapshots, and distribution intelligence snapshots.
- 24-hour and 7-day generation trends, moving averages, peak tracking, outage signals, volatility, and rolling health score.
- Distribution Intelligence module for transformer utilization, overload warnings, settlement growth pressure, and simulated loading trends.
- Clickable DisCo and GenCo drill-down pages with historical trends, forecasts, risk indicators, utilization charts, rankings, and automated analysis summaries.
- State Intelligence for all 36 Nigerian states plus FCT, including responsible DisCos, estimated allocation, peak demand, settlement growth, infrastructure stress, transformer risk, reliability, and peer ranking.
- Regional Intelligence across the six geopolitical zones with aggregate state trends and DisCo coverage.
- Hierarchical Geographic Intelligence map with State to LGA to Town/City to Community to Settlement drill-down, direct search, demand estimates, transformer loading, grid health, and upgrade recommendations.
- Public content pages for About, Contact, Privacy Policy, Terms of Use, Methodology, and Data Sources.
- Articles content hub with SEO-ready electricity explainers, search, category filtering …