Overall AUC higher than all "stratified" AUCs
AUC can be defined as $P(X_1 &gt; X_0)$ where $X_1$ is the score of a randomly chosen positive instance and $X_0$ is the score of a randomly chosen negative instance.
Like in Simpson's &quot;paradox&quot;, what you see could happen because the group has a relatively large effect on your target. For example, one group could be mostly positive, another could be mostly negative. The classifier might not work at all within each of the groups, but if it is merely able to predict the group we are in (or as in your case it is simply one of the inputs), it can have a high AUC.