WebSocket API

SoccerFootball.info is the first soccer API to offer a complete WebSocket real-time data service. Get live match events, real-time statistics, and live betting odds updates delivered instantly to your application through a persistent WebSocket connection — no polling, no delays.

Our WebSocket infrastructure is built for speed and reliability, with servers in Europe (EU) and Asia (AS) to ensure optimal connectivity worldwide.

Why WebSocket for Soccer Data?

Traditional REST API polling introduces latency and wastes bandwidth. Every poll request takes time, and most responses contain no new data. Our WebSocket API pushes data to your application the instant it changes, making it ideal for:

  • Live score trackers and widgets — display goals and match events as they happen

  • Real-time betting platforms — react to odds changes and match events instantly

  • In-play statistics dashboards — show possession, corners, shots, and cards in real-time

  • Automated trading systems — execute strategies based on live odds and statistics movements

  • Mobile applications — push notifications triggered by real-time match events

  • Fantasy sports platforms — update player performance data live during matches

Ultra-Low Latency with MAIN_REALTIME

The MAIN_REALTIME channel, exclusive to MEGA plan subscribers, delivers match events (goals, kickoffs, halftime, match end) with the absolute lowest latency available in the market.

When milliseconds matter — in live betting arbitrage, in-play trading, or competitive fantasy sports — MAIN_REALTIME gives you the edge over any other soccer data provider.

Available Channels

We offer 6 WebSocket channels to cover every real-time soccer data need:

Match Events

  • MAIN — Key match events: goals, halftime, match start and end. Available from PRO plan.

  • MAIN_REALTIME — Same events as MAIN with ultra-low latency delivery. MEGA plan only.

Live Statistics

  • STATS — Complete statistics snapshots including possession, attacks, shots, corners, fouls, cards, and xG. Available from ULTRA plan.

  • STATS_REALTIME — Real-time statistics deltas, delivering only changed values for instant updates and minimal bandwidth. MEGA plan only.

Live Odds

  • ODDS — Complete odds snapshots for all major markets (1X2, Over/Under, Asian Handicap, Corners, and more) from bet365 and Unibet. Available from ULTRA plan.

  • ODDS_REALTIME — Real-time odds deltas for instant market movement detection. MEGA plan only.

Competitive Advantages

  • First soccer API with WebSocket — no other soccer data provider offers real-time WebSocket streaming for matches, statistics, and odds

  • Real-time odds streaming — get live odds changes from bet365 and Unibet as they happen, not minutes later

  • Real-time statistics — possession, corners, shots, cards, xG — all delivered instantly as they update

  • Ultra-low latency — MAIN_REALTIME channel delivers the fastest match events in the industry

  • Low bandwidth — REALTIME channels send only changed data (deltas), minimizing network usage

  • Flexible subscriptions — subscribe to all matches, a single match, or an entire league

  • Reliable infrastructure — EU and AS server regions for optimal connectivity worldwide

Getting Started

  1. Subscribe to a plan that includes WebSocket access (PRO or higher)

  2. Obtain a WebSocket token via the /v1/ws/new REST endpoint

  3. Connect to the WebSocket server and subscribe to channels

  4. Start receiving real-time data

For complete integration instructions, code examples in JavaScript and Python, and detailed channel documentation, see the WebSocket Getting Started guide.

Bridging REST and WebSocket

Our WebSocket system uses its own real-time IDs for matches, teams, and championships. To seamlessly bridge between REST API data and WebSocket real-time data, use these dedicated mapping endpoints:

These endpoints return both the ws_realtime ID (used in WebSocket channels) and the rest_releated ID (used in REST API endpoints) for every entity, enabling you to cross-reference data between the two systems effortlessly.

Last updated