A web dashboard with movable widgets, including weather, traffic, calendar, and GitHub projects. Built with SvelteKit and designed to be hosted on Cloudflare Pages.
- 🎯 Movable Widgets: Drag and drop widgets to customize your dashboard layout
- 🌤️ Weather Widget: Displays current weather information
- 🚗 Traffic Widget: Shows traffic conditions for common routes
- 📅 Calendar Widget: Displays upcoming events and appointments
- 🐙 GitHub Personal Repositories: Shows your personal GitHub repositories when logged in
- 🏢 Organization Projects: Shows projects from all your GitHub organizations in tile format
- 🔐 GitHub OAuth: Sign-in to view your GitHub projects and organization repositories
- 🟠 Cloudflare Widget: Connect a read-only Cloudflare API token to see traffic for your domains, deployment status for Pages projects, and invocation stats for Workers — with an Overview rollup and interactive charts. Tokens don't expire, so you stay connected across devices.
- 🌌 NebulaKit Site Widget: Connect any site built on
NebulaKit with the stats
token its owner issues on
/admin/analyticsto see the site's traffic, audience, growth and Cloudflare plan usage — the same numbers as its own admin dashboard, read-only - 📊 Google Analytics Widget: Connect a GA4 property for realtime and
historical traffic (needs
GA_OAUTH_CLIENT_ID/GA_OAUTH_CLIENT_SECRET) - 🪙 Crypto Widget: Spot price and chart for any CoinGecko-listed coin
- 🤖 Copilot Usage: Copilot engagement metrics for your organizations
- ☁️ Cross-Device Sync: Widget layout, location, and connections sync across browsers/devices for the same logged-in user (Cloudflare KV)
- Node.js 20+
- npm
- Clone the repository:
git clone https://github.com/starspacegroup/dashboard.git
cd dashboard- Install dependencies:
npm install- Create a
.envfile based on.env.example:
cp .env.example .env-
(Optional) Configure GitHub OAuth:
- Go to GitHub Developer Settings
- Create a new OAuth App
- Set the callback URL to:
http://localhost:4200/auth/callback/github - Add your Client ID and Secret to the
.envfile - The app will request the following scopes:
read:user,user:email,read:org,repo,read:project,manage_billing:copilot
-
Start the development server:
npm run dev- Open http://localhost:4200 in your browser
On localhost, npm run dev skips sign-in and opens on a dashboard with one
widget of every type, each carrying sample data, so you can work on the UI
without connecting a GitHub, Google Analytics, Cloudflare or NebulaKit account. A
DEV PREVIEW · SAMPLE DATA badge stays in the header while it is on.
From any other address the dev server answers on — a LAN IP, or the hostname
npm run dev:tunnel publishes — the sign-in page offers a Continue as Dev
Preview button beside the GitHub one, so you can open the dev dashboard on a
phone without registering an OAuth callback for that host. Signing out ends the
preview and gives you the real GitHub flow back, on any host.
The GitHub, Analytics, Cloudflare and NebulaKit numbers are generated, and the Traffic
widget draws a sample board when there is no GOOGLE_MAPS_API_KEY (set one and
you get the real map). Weather, geocoding and crypto are keyless APIs, so those
widgets show live data.
Set DEV_AUTH_BYPASS=false in .env to test the real sign-in flow. The preview
is compiled out of every build, so a deployed copy always goes through real
GitHub OAuth.
To build for production:
npm run buildTo preview the production build:
npm run previewThis app is configured to deploy to Cloudflare Pages:
- Push your code to GitHub
- Connect your repository to Cloudflare Pages
- Use the following build settings:
- Build command:
npm run build - Build output directory:
.svelte-kit/cloudflare
- Build command:
- Add your environment variables in Cloudflare Pages settings:
GITHUB_IDGITHUB_SECRETAUTH_SECRETAUTH_TRUST_HOST=trueDASHBOARD_STATE_ENCRYPTION_KEY_VERSION(for example,v1)DASHBOARD_STATE_ENCRYPTION_KEYS(a JSON keyring such as{"v1":"<independently generated secret>"})
Dashboard snapshots use the active version in DASHBOARD_STATE_ENCRYPTION_KEYS,
not AUTH_SECRET. To rotate encryption keys, add the new version without
removing the old one, change DASHBOARD_STATE_ENCRYPTION_KEY_VERSION, deploy,
and retain both versions until old-version snapshots are next written or
deliberately migrated. Legacy plaintext and unversioned enc:v1 snapshots move
to a separately keyed encrypted migration record on read, so that migration
cannot overwrite a concurrent normal write. Replacement and fallback values
coexist for a bounded propagation window because Workers KV does not make
cross-key writes and deletes visible atomically; the legacy value then expires.
Existing enc:v1 snapshots fall back to the current AUTH_SECRET. If that
secret must rotate before migration finishes, temporarily set
DASHBOARD_STATE_LEGACY_AUTH_SECRETS to a JSON array containing the old value.
- Framework: SvelteKit 2
- Language: TypeScript
- Styling: CSS (Custom Properties)
- Authentication: Auth.js (NextAuth.js for SvelteKit)
- Deployment: Cloudflare Pages
- Adapter: @sveltejs/adapter-cloudflare
MIT
Internal planning, design and docs live in a separate private repository,
starspacegroup/dashboard-umbrella, which has this repository checked out at dashboard/. Nothing in
it is needed to build or run this one.

