  Weyl semimetals have emerged as a promising quantum material system to
discover novel electrical and optical phenomena, due to their combination of
nontrivial quantum geometry and strong symmetry breaking. One crucial class of
such novel transport phenomena is the diode effect, which is of great interest
for both fundamental physics and modern technologies. In the electrical regime,
giant electrical diode effect (the nonreciprocal transport) has been observed
in Weyl systems. In the optical regime, novel optical diode effects have been
theoretically considered but never probed experimentally. Here, we report the
observation of the nonlinear optical diode effect (NODE) in the magnetic Weyl
semimetal CeAlSi, where the magnetic state of CeAlSi introduces a pronounced
directionality in the nonlinear optical second-harmonic generation (SHG). By
physically reversing the beam path, we show that the measured SHG intensity can
change by at least a factor of six between forward and backward propagation
over a wide bandwidth exceeding 250 meV. Supported by density-functional theory
calculations, we establish the linearly dispersive bands emerging from Weyl
nodes as the origin of the extreme bandwidth. Intriguingly, the NODE
directionality is directly controlled by the direction of magnetization. By
utilizing the electronically conductive semimetallic nature of CeAlSi, we
demonstrate current-induced magnetization switching and thus electrical control
of the NODE in a mesoscopic spintronic device structure with current densities
as small as 5 kA/cm$^2$. Our results advance ongoing research to identify novel
nonlinear optical/transport phenomena in magnetic topological materials. The
NODE also provides a way to measure the phase of nonlinear optical
susceptibilities and further opens new pathways for the unidirectional
manipulation of light such as electrically controlled optical isolators.
