Skip to content
Blog

Why We Built Our Own Poker Hand Replayer and Parser

Simone Gauli

About three years ago, we just wanted to look at a few poker hands online. They were normal hand histories from PokerStars and GGPoker, nothing exotic. What should have taken ten seconds turned into a frustrating loop of broken tools.

One online poker hand replayer showed wrong stack sizes and pot totals. Another loaded a couple of hands and failed on the rest. Worse, if you played on more than one site, there was no single place you could trust. You had to bounce across a dozen different websites trying to find a replayer that accepted your poker room, and even when you found one that seemed to work, it often skipped actions or displayed numbers that did not add up.

That frustration is the reason we built our own hand history parser and the OpenGTO poker hand replayer from scratch.

Copy link to headingThe core rule: refuse broken hands

Most poker replayers follow a forgiving philosophy. If a line in the hand history looks weird, skip it, guess a number, and still draw the table. On the surface that feels helpful because the hand loads instead of showing an error.

In practice, it is the worst thing a study tool can do.

A hand history is not only for watching cards animate across a felt. It feeds your session profit, effective stacks, pot odds, position stats, and GTO review. If a parser quietly drops an uncalled bet, misreads an ante, or misses a side pot, the replay looks almost right at a glance while your numbers underneath are completely wrong. Bad parses pollute your database and ruin the integrity of every stat built on top of them.

So we built our parser around the opposite rule: every hand has to prove its math before we accept it. If the numbers do not balance from the first blind to the final payout, we refuse to play the hand.

Copy link to headingHow our parser checks every hand

When you paste a hand or upload a full session file into OpenGTO, the raw text goes through a strict multi-stage pipeline before it ever reaches the replayer.

Copy link to heading1. Room detection and normalization

Poker rooms do not share a standard export format. Most export plain text, some change their header wording depending on whether a hand is cash or Zoom, and networks like iPoker export raw XML <session> files alongside text histories.

Our entry layer normalizes the raw input first. If you drop in an iPoker XML session file, we validate its XML structure and convert each <game> block into structured text before room detection even runs. From there, we identify the room in a deliberate order so overlapping headers never collide (for example, 1WinPoker Hand # contains GGPoker's Poker Hand # marker, and BlitzPoker only names itself on the table line instead of the first line).

Next, the splitter separates single hands from multi-hand session files and strips out noise like email separator lines or Winamax tournament summary blocks. When you upload a multi-hand collection, every hand is parsed on its own. If one hand in a 500-hand file is truncated or corrupted, we report that specific hand instead of rejecting the entire session.

Copy link to heading2. Parsing into one unified hand model

Every supported room gets translated into the exact same internal hand structure. That means our replayer, big-blind converter, position calculator, effective stack calculation, hero profit math, and automatic hand tagger (preflop, postflop, and showdown tags) all run on one consistent schema.

We also avoid standard floating-point math for money. Cash amounts in $, €, £, ¥, and ₮ are converted with decimal-safe arithmetic into integer units so JavaScript rounding errors like 0.1 + 0.2 never leak into pots or stacks.

Copy link to heading3. Headless replay verification

Passing a schema check only tells you the shape of the data looks valid. It does not prove the hand makes sense on a poker table.

Before our parser finalizes any hand, it runs the parsed result through our replay engine in headless mode, stepping through every single action from posting blinds to showdown and checking three hard invariants:

  1. No floating-point drift. Every chip and currency value in the parsed hand must stay an exact integer (with a dedicated exception only for CoinPoker's native decimal values).

  2. No negative numbers anywhere. At every single action in the hand, every player's remaining stack, the total pot, each displayed pot, and each seat's committed chips must stay at zero or above.

  3. No chips left in the middle. Once the hand reaches showdown (outside of cash-out spots), every displayed main pot and side pot must empty cleanly to zero. Every chip put into the pot has to be accounted for by winners, split pots, uncalled bet returns, or rake.

If even one cent is left unaccounted for at showdown, or a player's stack dips below zero on the turn, the parser rejects the hand. That single decision caught hundreds of subtle room-specific quirks while we were building the engine.

Copy link to headingWhy supporting multiple poker rooms is harder than it looks

If you have never opened raw hand history files from five different poker sites, it is easy to assume they are mostly the same text with different headers. They are not. Even sites that loosely copy PokerStars invent their own edge cases, omit actions, or write contradictory summaries.

Rather than copying and pasting the full poker rules 18 times, we group rooms into shared format families where possible and isolate each site's quirks into small, testable normalizers and polyfills. That keeps the core action engine clean while still handling the messy reality of real hand histories.

Here is how our parser supports all 18 active rooms today:

Poker Room

Format Family

Notable Quirks Handled

Export Guide

PokerStars

PokerStars native

Cash, Zoom, tournaments, split info headers, plus mixed games including Stud and Draw

PokerStars guide

GGPoker

GGPoker family

Rush & Cash, Cash Drops, Flipout MTT full-stack antes, and Hero alias mismatches

GGPoker guide

Winamax

Dedicated parser

Wrong or inactive button seats, missing uncalled bets hidden in fake side pots, side-pot backfilling

Winamax guide

WPN (ACR)

WPN family

Rebuilding missing uncalled bet returns, summary-won reconciliation, side-pot reconstruction

WPN guide

iPoker

Dedicated + XML

Both raw XML <session> files and text exports, reconstructed uncalled bets, rounded-rake recovery

iPoker guide

888poker

Dedicated parser

Covers 888poker and 888.it, button fallback from blinds, reconstructed uncalled bets

888poker guide

Ignition

Bovada/Ignition

Anonymous seat names, [ME] hero detection, seat remapping, straddles, all-player hole cards

Ignition guide

Bovada

Bovada/Ignition

Anonymous seat labels (Dealer, Big Blind), limit extraction from actions, straddles

Bovada guide

CoinPoker

Dedicated (v1 & v2)

Supports both legacy v1 and newer v2 formats, decimal chip amounts, straddles, all-in antes

Coming soon

BetRivers

PokerStars family

Normalizes showdown headers, Splash the Pot (STP) cash drops, and mucked-hand wins

BetRivers guide

Betclic

Dedicated parser

Key-value headers (Site: Betclic), uncalled bet reconstruction, cash-game rake reconciliation

Betclic guide

Phenom Poker

PokerStars family

Cash tables that omit button declarations (derived from blinds), reconstructed uncalled bets

Coming soon

Full Tilt Poker

Dedicated parser

Classic Full Tilt text format, button resolution from header line or posted blinds

Coming soon

BlitzPoker

WPN family

Table-line room detection, source normalization into the WPN pipeline

Coming soon

PPPoker

GGPoker family

Parsed through the GGPoker-compatible pipeline

Coming soon

RedDragon, Sisal, 1Win

PokerStars family

Shared network pipeline with room-specific header normalization (such as 1Win tournament IDs)

All room guides

Copy link to headingA few real examples of room quirks we had to solve

To give you an idea of why generic parsers break so often, here are a few real cases our engine deals with every day:

  • Winamax fake side pots and button seats: Winamax does not print Uncalled bet returned lines. Instead, it drops the uncalled chips into the pot, invents a side pot at the end of the street, and returns that side pot to the bettor in the summary. Winamax also exports hands where the declared button seat is empty or belongs to an inactive tournament player. Our parser strips inactive tournament seats, recalculates the true button from the blinds, and converts those fake side pots back into real uncalled returns.

  • GGPoker Flipouts and Hero aliases: In GGPoker Flipout tournaments, every player posts an ante equal to their full stack, so the chip leader posts more than anyone can cover and GGPoker emits an uncalled bet line to refund the excess. On top of that, some GGPoker histories label the hero as Hero in the seat list while using the player's actual nickname in every action line. We normalize both before the hand hits the replay engine.

  • iPoker XML and missing uncalled bets: iPoker never writes uncalled bet return lines, and it rounds down each winner's rake share in split pots, which can leave a cent or two missing between the contested pot and the payout. We rebuild uncalled returns straight from street investments and recover rounding cents without masking real pot errors.

  • BetRivers Splash the Pot (STP): When STP bonus chips make up the entire pot, BetRivers prints $0.00 for the main and side pots in the summary line. We extract the STP amount as a cash drop and reconstruct the true pot split from the collected lines.

  • CoinPoker v1 and v2: CoinPoker changed its hand history format over time, so we maintain two distinct parsers behind the scenes and route each hand automatically based on its header.

Copy link to headingWhere the parser and replayer stand today

Three years in, what started as a personal annoyance has grown into a battle-tested parsing and replay engine:

  • 18 poker rooms actively supported, with Bodog currently in progress.

  • Both single hands and full session uploads, with per-hand error isolation so one corrupted line never blocks the rest of your session.

  • More than just Hold'em. Beyond No-Limit and Limit Hold'em, our engine parses PLO, PLO5, PLO6, Omaha Hi/Lo, 5-Card PLO Hi/Lo, 7-Card Stud and Stud Hi/Lo (including buttonless dealing), 2-7 Single Draw, 2-7 Triple Draw, 5-Card Draw, Badugi, and Badeucy.

  • Built-in study metadata. Every valid hand automatically gets positions, big-blind unit conversion, effective stacks, hero profit, and preflop, postflop, and showdown tags.

  • Backed by real regression fixtures. Every time a user or a room update exposes a new edge case, that hand goes into our test suite of real single hands and full multi-hand collections across all supported rooms. Fixing one room never quietly breaks another.

Copy link to headingTry it with your own hands

If you are tired of hunting for a working replayer every time you switch poker rooms, or tired of replayers that silently fudge the pot size, paste a hand or drop a session file into the OpenGTO poker hand replayer.

Need help locating your hand history files first? Check our step-by-step poker room export guides for PokerStars, GGPoker, Winamax, iPoker, WPN, 888poker, Ignition, BetRivers, and Betclic.

Ready to replay your hands?

This site uses tracking technologies. You may opt in or opt out of the use of these technologies.