We have recently resurrected a bifunctional ancestral enzyme that putatively existed prior to the functional diversification into modern-day haloalkane dehalogenases (EC 3.8.1.5) and coelenterazine-converting Renilla luciferase (EC 1.13.12.5). This ancestor, which exhibited markedly enhanced thermal stability, was subjected to InDel mutagenesis to uncover molecular determinants important for the evolution of luciferase activity. Generated libraries were screened and the best hits carrying alterations in three hot-spot regions were comprehensively characterized. The most potent hit was crystallized and its 2-Å-resolution structure was solved. There are two monomers (A and B) present in the asymmetric unit, which form a non-crystallographic dimer related by 2-fold axis of symmetry. Although the overall structures of the both monomers are very similar, they markedly differ in the positioning of the cap-domain-forming α4 helix. Moreover, electron density maps for the α4 helix and its flanking loops are not perfectly resolved, some side chains are poorly visible or not seen at all, which illustrates a conformational flexibility in this region. Monomer A is similar to the template structure, although the replacement of a bulky phenylalanine by proline makes the active-site cavity spatially bigger. However, the active-site access tunnel in monomer B is markedly reduced due to the α4 helix distortion. Complementary protein simulations supported that the gained conformational flexibility of the cap-domain-forming elements favours the accommodation of bulkier substrates such as coelenterazine. Collectively, we highlight enzyme molecular determinants required for evolvability of luciferase activity, and propose a new framework to switch enzyme functions by engineering of flexible elements.