German village Igelheim's backward priest hopes his sons to succeed him after education in the bishop's cathedral school, but the elder succumbs to disease and the youngest lacks any intellectual drive. Traveling teacher Aesculapius arranges for the inquisitive daughter Johanna to be enrolled too, against their father's wishes. Unfit for the boys-only dorm, she gets to stay with count Gerold, incurring his wife's due jealousy. She's to be dismissed, but survives a Viking pillaging slaughter and assumes brother Johannes's identity to join a monastery, where she becomes the infirmary's trainee. Fleeing exposure as female, she arrives in Rome. As a protégée of rivals in the viper nest-like papal court, she ends up elected as pope, but carries count Gerold's baby, guaranteeing exposure.