Bacillus subtilis BsDyP belongs to class I of the dye-decolorizing peroxidase (DyP) family of enzymes and is an interesting biocatalyst due to its high redox potential, broad substrate spectrum and thermostability. This work reports the optimization of BsDyP using directed evolution for improved oxidation of 2,6-dimethoxyphenol, a model lignin-derived phenolic. After three rounds of evolution, one variant was identified displaying 7-fold higher catalytic rates and higher production yields as compared to the wild-type enzyme. The analysis of X-ray structures of the wild type and the evolved variant showed that the heme pocket is delimited by three long conserved loop regions and a small α helix where, incidentally, the mutations were inserted in the course of evolution. One loop in the proximal side of the heme pocket becomes more flexible in the evolved variant and the size of the active site cavity is increased, as well as the width of its mouth, resulting in an enhanced exposure of the heme to solvent. These conformational changes have a positive functional role in facilitating electron transfer from the substrate to the enzyme. However, they concomitantly resulted in decreasing the enzyme’s overall stability by 2 kcal mol−1, indicating a trade-off between functionality and stability. Furthermore, the evolved variant exhibited slightly reduced thermal stability compared to the wild type. The obtained data indicate that understanding the role of loops close to the heme pocket in the catalysis and stability of DyPs is critical for the development of new and more powerful biocatalysts: loops can be modulated for tuning important DyP properties such as activity, specificity and stability.