Commander damage is a format rule, not a game rule found in the Comprehensive Rules proper, but it is codified in the official Commander rules. The key principle is that commander damage is tracked by which object dealt the damage (the commander itself), not by who controlled it at the time the damage was dealt.
Under CR 903.10a (and the Commander format rules), a player who has been dealt 21 or more combat damage by a single commander over the course of the game loses the game. This tracking is tied to the commander's identity, not its controller. So if an opponent temporarily gains control of your commander via a card like Bribery or Oko, Thief of Crowns and attacks with it, any combat damage it deals to you still counts toward your commander-damage total from that commander.
Similarly, if your commander is stolen and deals 21 damage to a third player across multiple turns (some under your control, some under the opponent's control), all of that damage accumulates toward the 21-damage threshold for that third player from that specific commander.
Concrete example: You control Atraxa, Praetors' Voice as your commander. An opponent casts Insurrection and attacks you with Atraxa, dealing 7 combat damage. Later you get Atraxa back and deal 14 more combat damage to that same opponent. That opponent has now received 21 commander damage from Atraxa and loses the game, even though 7 of those points were dealt while an opponent controlled it.
Note that if a commander leaves the battlefield and returns, it is still the same commander for damage-tracking purposes (CR 903.11), so zone changes do not reset the counter either.
Unofficial fan resource — not affiliated with or endorsed by Wizards of the Coast. Answers are AI-generated estimates grounded in the Comprehensive Rules and are not a substitute for an official judge. Verify anything match-critical.