Prenyltransferases in cyanobactin biosynthesis are of growing interest as peptide alkylation biocatalysts because of their ability to prenylate various noncognate substrates1. However, the prenylation modes catalyzed by this family of enzymes have been limited to dimethylallylation (C5) or geranylation (C10)2. Here, we employed structure-guided engineering of the prenyl-binding pocket of a His-C-geranyltransferase LimF3, repurposing it for the dimethylallylation and farnesylation of histidine. Moreover, the obtained knowledge about the key residues defining the prenyl-donor selectivity has allowed for rational engineering of another cyanobactin prenyltransferase to furnish artificial variants with farnesylation activity. To our best knowledge, the artificial cyanobactin prenyltransferase variants developed in this study represent the first examples of farnesyltransferases in this family. In summary, this work has allowed for the manipulation of the prenyl specificity of cyanobactin prenyltransferases to access non-naturally occurring prenylation modes and revealed an important molecular rationale for broadening the chemical space covered by this class of enzymes.