A browser-first cockpit dashboard and server launcher for X4: Foundations.
x4-dashboard combines:
- a React + Arwes dashboard UI
- a Node.js server that aggregates game state
- a Lua bridge mod for X4
- a Windows Electron Server Launcher for easy local hosting
The main product direction is simple: run one server, then open the dashboard from browsers on the same machine or other devices on your LAN.
- Want the easiest packaged setup? Start with the Player Setup Guide.
- Want to run from source or contribute? Continue with the setup steps in this README.
- Live ship, combat, mission, research, and comms telemetry
- Browser-based multi-device cockpit layouts
- Host-side key press integration with configurable bindings
- Mock mode for previewing the full dashboard without starting X4
- Windows Server Launcher that shows local and LAN URLs
npm run install:allnpm run dev:mockThis starts:
- the mock server
- the Vite client
- the Electron Server Launcher
Use the launcher to open the dashboard, or go directly to http://localhost:3000.
The mock buttons and simulated data are available only in this mode.
If you want the packaged player setup instead of a source checkout, use the Player Setup Guide.
This repository is source-only. The production frontend in server/public/ is generated locally and ignored by Git.
Build the frontend:
npm run buildStart the built app:
npm startThis opens the Electron Server Launcher and runs the built server/client pair behind it.
Open the dashboard from:
http://localhost:3001on the host machinehttp://<your-lan-ip>:3001on other devices in the same trusted network
The Electron app is a Server Launcher, not the main dashboard client.
It is responsible for:
- starting the local server
- showing local and LAN URLs
- editing host-side settings
- editing host-side key bindings
- opening the server log location
Run it in development:
npm run devThis does not build a desktop bundle. It only starts the Electron shell against the live Vite client.
Run it against the locally built production app:
npm run build
npm startBuild Windows artifacts:
npm run desktop:distArtifacts are written to release/.
Branding assets for the launcher and installer live in launcher/assets/.
The intended usage model is:
- start the server on one machine
- point the Lua mod at that machine
- open the dashboard from browsers on tablets, laptops, side monitors, or other nearby devices
That makes x4-dashboard much better suited to multi-screen cockpit setups than a native-client-only architecture.
- Start the host machine with
npm startor the packaged Server Launcher - Use the LAN URL shown by the launcher as the default address for other devices
- Keep the local URL for the host machine itself
- Leave remote controls disabled unless you explicitly want LAN clients to trigger host-side inputs
This app can simulate local key presses on the machine where the server is running.
- Use it only on a trusted local machine or private LAN
- Do not expose the server directly to the public internet
- Remote control is localhost-only by default unless enabled from the Server Launcher
- The game window may need focus or borderless mode for reliable input
Current release packaging is split into separate artifacts:
x4-dashboard-server-<version>.zip/.tar.gz- standalone server packagex4-dashboard-lua-mod-<version>.zip- standalone X4 Lua mod packagex4-dashboard-server-launcher-<version>-portable.exe- portable Windows launcherx4-dashboard-server-launcher-<version>-setup.exe- Windows installer
Build release bundles locally:
npm run release:bundleBuild release validation:
npm run release:checkThe project currently has two Dokploy-managed deployment targets:
landing/throughDockerfile.landing- mock mode through
Dockerfile.mock
Tagged releases also publish versioned GHCR images from this repository:
ghcr.io/fpiechowski/x4-dashboard-landing:vX.Y.Zghcr.io/fpiechowski/x4-dashboard-mock:vX.Y.Z
Infrastructure repositories such as nebula should consume those published images instead of rebuilding them.
GitHub Pages is no longer part of the active deployment model for this repository.
The following host-side settings now live in the Server Launcher:
- allow remote controls
- AutoHotkey executable path
- force activate game window
- game window title matching
- key bindings used for host-side key press simulation
These values are persisted server-side for the machine running the host.
Environment variables still exist, but they should mainly be treated as startup defaults or advanced overrides.
| Variable | Default | Description |
|---|---|---|
PORT |
3001 |
Server port |
MOCK |
unset | Forces mock mode when set to true |
AUTOHOTKEY_PATH |
unset | Explicit path to AutoHotkey64.exe |
X4_FORCE_ACTIVATE |
false |
Try to focus the game window before sending keys |
X4_WINDOW_TITLE |
X4 |
Window title fragment used for focus matching |
ALLOW_REMOTE_CONTROLS |
false |
Allows remote access to /api/keypress and keybinding management |
Precedence notes:
PORTandMOCKare still startup-time settings- host control settings should be changed in the Server Launcher
- env vars act as defaults until launcher-managed runtime settings are saved
The Lua bridge source lives in game-mods/x4_dashboard_bridge/.
For releases, use the dedicated Lua mod zip and copy the included folder into your X4 extensions directory:
X4 Foundations/extensions/x4_dashboard_bridge/
The packaged extension uses its own X4 content id, so it does not conflict with the original Mycu mod.
Config inside the packaged extension:
host = '127.0.0.1'
port = 3001If your dashboard server runs on another LAN machine, point host to that machine.
Main commands:
npm run dev # hot reload + real server + launcher
npm run dev:mock # hot reload + mock server + launcher
npm start # built app through the launcher
npm run serve # advanced: built server only
npm run build # build client into server/public/
npm run build:landing # build the landing page
npm run typecheck # main validation step
npm run typecheck:landing # landing page typecheck
npm run test # run automated test suite
npm run test:watch # run tests in watch mode
npm run test:coverage # run tests with coverage report
npm run release:check # typecheck + frontend build
npm run desktop:dist # build Windows launcher artifacts
npm run release:bundle # build standalone server + Lua bundlesCurrent validation status:
- automated test suite available via Jest (server-side)
- no linter configured yet
npm run typecheck,npm run typecheck:landing, andnpm testare the main validation commands
Data flow:
- the X4 Lua mod posts widget payloads to
POST /api/data server/utils/normalizeData.jsstrips X4 formatting codesserver/dataAggregator.jsmerges partial updates into durable game state- the server broadcasts game state over WebSocket
- browser dashboards render the live state and call
POST /api/keypressfor host-side actions
x4-dashboard/
|- client/ React + TypeScript frontend
|- launcher/ Windows Server Launcher
|- game-mods/x4_dashboard_bridge/ Lua bridge source
|- landing/ Public landing page
|- server/ Express + WebSocket backend
|- server/public/ Generated frontend build output
|- docs/screenshots/ README screenshots
docs/player-guide.md- non-technical setup and first-use guideCONTRIBUTING.md- contribution guideSECURITY.md- security policyRELEASE.md- release checklistROADMAP.md- current roadmapCHANGELOG.md- release historylanding/README.md- landing page development and deployment notesAGENTS.md- instructions for coding agents
- The project is playable, but still evolving
- Remote hosting is not a supported security model
- Some launcher and LAN workflows are still being refined
Special thanks to Mycu, author of X4 External App, for the original mod that proved out this integration path.
MIT - see LICENSE.













