The most useful strategies for the alkylation of allylic systems are related to the Tsuji–Trost reaction or the use of different Lewis acids. Herein we report a photocatalytic approach for the allylation reaction of a variety of nucleophiles, such as heteroarenes, amines and alcohols. This method is compatible with a large variety of pyrroles and indoles, containing different substituents such as electron-withdrawing and electron-donating groups, unprotected nitrogen atoms and bromo derivatives. Moreover, this methodology enables the chromoselective synthesis of
Z
- or
E
-allylated compounds. While the use of UV-light irradiation has allowed the synthesis of the previously inaccessible
Z
-allylated products,
E
-isomers are prepared simply by changing both the light source to the visible region, and the catalytic system. Based on mechanistic and photochemical proofs, laser flash photolysis studies and DFT calculations, a rational mechanism is presented.