Expected Goals (xG) for a basketball free throw
Built for hobbyists & makers exploring it for fun. Play with real physics and math, no license and no setup — just open and tinker. Simulate a basketball free throw live below — adjust the inputs and watch it respond, right in your browser.
Controls
Expected goals rates every shot by the probability an average player would score from that spot, learned from thousands of historical shots. The two biggest drivers are distance and angle to goal — a tap-in near the six-yard box is worth 0.8 xG, a long-range effort barely 0.03. Summing xG over a match reveals who truly deserved to win, beyond the scoreline. Click to place a shot.
Data Inspector
Governing equation
Runs locally in your browser — free forever. Scale to the cloud when reality gets heavy.
More with Expected Goals (xG)
Frequently asked questions
- Is this good for hobbyists & makers?
- Yes — this version of "Expected Goals (xG) for a basketball free throw" is framed for hobbyists & makers exploring it for fun. Play with real physics and math, no license and no setup — just open and tinker.
- Do I need to install anything?
- No. It runs in any modern browser, free, with no account required.