On-surface polymerization
is a powerful bottom-up approach that
allows for the growth of covalent architectures with defined properties
using the two-dimensional confinement of a highly defined single-crystal
surface. Thermal heating is the preferred approach to initiate the
reaction, often via cleavage of halogen substituents from the molecular
building blocks. Light represents an alternative stimulus but has,
thus far, only rarely been used. Here, we present a direct comparison
of on-surface polymerization of dibromo-anthracene molecules, induced
either thermally or by light, and study the differences between the
two approaches. Insight is obtained by a combination of scanning tunneling
microscopy, locally studying the polymer shape and size, and X-ray
photoelectron spectroscopy, which identifies bond formation by averaging
over large surface areas. While the polymer length increases slowly
with the sample heating temperature, illumination promotes only the
formation of short covalent structures, independent of the duration
of light exposure. Moreover, irradiation with UV light at different
sample temperatures highlights the important role of molecular diffusion
across the surface.