Abstract The azole-based P450 inhibitor ketoconazole is used to treat fungal infections and functions by blocking ergosterol biosynthesis in yeast. Ketoconazole binds to mammalian P450 enzymes and this can result in drug-drug interactions and lead to liver damage. To identify protein-drug interactions that contribute to binding specificity and affinity, we determined the crystal structure of ketoconazole complexed with P450eryF. In the P450eryF/ketoconazole structure, the azole moiety and nearby rings of ketoconzole are positioned in the active site similar to the substrate, 6-deoxyerythronolide B, with the azole nitrogen atom coordinated to the heme iron atom. The remainder of the ketoconazole molecule extends into the active-site pocket, which is occupied by water in the substrate complex. Binding of ketoconazole led to unexpected conformational changes in the I-helix. The I-helix cleft near the active site has collapsed with a helical pitch of 5.4 Å compared to 6.6 Å in the substrate complex. P450eryF/ketoconazole crystals soaked in 6-deoxyerythronolide B to exchange ligands exhibit a structure identical with that of the original P450eryF/substrate complex, with the I-helix cleft restored to a pitch of 6.6 Å. These findings indicate that the I-helix region of P450eryF is flexible and can adopt multiple conformations. An improved understanding of the flexibility of the active-site region of cytochrome P450 enzymes is important to gain insight into determinants of ligand binding/specificity as well as to evaluate models for catalytic mechanism based on static crystal structures.