Seeded free-electron laser driven by a compact laser plasma accelerator

Free-electron lasers generate high-brilliance coherent radiation at wavelengths spanning from the infrared to the X-ray domains. The recent development of short-wavelength seeded free-electron lasers now allows for unprecedented levels of control on longitudinal coherence, opening new scientific avenues such as ultra-fast dynamics on complex systems and X-ray nonlinear optics. Although those devices rely on state-of-the-art large-scale accelerators, advancements on laser-plasma accelerators, which harness gigavolt-per-centimetre accelerating fields, showcase a promising technology as compact drivers for free-electron lasers. Using such footprint-reduced accelerators, exponential amplification of a shot-noise type of radiation in a self-amplified spontaneous emission configuration was recently achieved. However, employing this compact approach for the delivery of temporally coherent pulses in a controlled manner has remained a major challenge. Here we present the experimental demonstration of a laser-plasma accelerator-driven free-electron laser in a seeded configuration, where control over the radiation wavelength is accomplished. Furthermore, the appearance of interference fringes, resulting from the interaction between the phase-locked emitted radiation and the seed, confirms longitudinal coherence. Building on our scientific achievements, we anticipate a navigable pathway to extreme-ultraviolet wavelengths, paving the way towards smaller-scale free-electron lasers, unique tools for a multitude of applications in industry, laboratories and universities. Researchers demonstrate a laser-plasma accelerator-driven free-electron laser in a seeded configuration, where control over the radiation wavelength and longitudinal coherence are achieved.

Free-electron lasers generate high-brilliance coherent radiation at wavelengths spanning from the infrared to the X-ray domains. The recent development of short-wavelength seeded free-electron lasers now allows for unprecedented levels of control on longitudinal coherence, opening new scientific avenues such as ultra-fast dynamics on complex systems and X-ray nonlinear optics. Although those devices rely on state-of-the-art large-scale accelerators, advancements on laser-plasma accelerators, which harness gigavolt-per-centimetre accelerating fields, showcase a promising technology as compact drivers for free-electron lasers. Using such footprint-reduced accelerators, exponential amplification of a shot-noise type of radiation in a self-amplified spontaneous emission configuration was recently achieved. However, employing this compact approach for the delivery of temporally coherent pulses in a controlled manner has remained a major challenge. Here we present the experimental demonstration of a laser-plasma accelerator-driven free-electron laser in a seeded configuration, where control over the radiation wavelength is accomplished. Furthermore, the appearance of interference fringes, resulting from the interaction between the phase-locked emitted radiation and the seed, confirms longitudinal coherence. Building on our scientific achievements, we anticipate a navigable pathway to extreme-ultraviolet wavelengths, paving the way towards smaller-scale free-electron lasers, unique tools for a multitude of applications in industry, laboratories and universities.
Research and daily life have been profoundly impacted by the invention of the laser. This impact has grown with the expansion of available parameters thanks to innovations in system architecture and gain media. With the advent of ultrashort-pulse and high-peak-power technology based on chirped pulse amplification 1 , lasers have pushed the frontiers of science, opening the door to new applications in relativistic-intensity laser-matter interactions 2 , of which laser-plasma acceleration 3 is a prominent example. However, fundamental limitations remain regarding the generation of X-ray radiation, as light amplification is based on the population inversion of electronic states, typically in a solid-state material. Free-electron lasers (FELs) 4 , in contrast, harness a completely different gain medium, where relativistic electron beams wiggle in a periodically alternating magnetic field. FELs have undergone game-changing progress over recent decades. The first low-gain infrared FELs providing picojoule pulse energies 5 paved the way to higher gain 6 , shorter wavelengths [7][8][9][10][11][12] and, finally, mature hard-X-ray tunable systems 13,14 . Applications of FELs advanced simultaneously, and X-ray FELs are now established as unique high-brilliance tools for the investigation of matter with atomic resolution at femto-to attosecond timescales 15 . This progress has been enabled by continuous improvements in electron-beam-source quality, supported by the next generation of particle colliders 16 . However, the length of such state-of-the-art linear accelerators increases with the beam energy, and thus involves high investment and high operational costs. FEL facilities presently extend over 350 m for beam energies of 1 GeV and FEL wavelengths in the extreme-ultraviolet (EUV) range (for example, FERMI 12 ), Article https://doi.org/10.1038/s41566-022-01104-w Electrons accelerated by Laser) beam manipulation line 56 . A schematic of the experimental layout is provided in Fig. 1. The LPA is operated in a tailored self-truncated ionization-induced injection scheme 57 , employing beam loading to limit the energy spread 40 . The LPA performance is optimized for high-charge and low-divergence beams. The latter is achieved by shaping the gas-density profile directly at the accelerator exit to induce a plasma lens effect, resulting in electron beams with high spectral charge density. Discarding off-energy and low-charge-density shots, which cannot lead to FEL observation (Extended Data Fig. 1), the electron beams exhibit a peak energy E e of 188 MeV, with a statistical standard deviation (s.d.) of 6 MeV, a relative energy spread σ E of 6.3 ± 0.8% (root-mean square (r.m.s.) ± s.d.), resulting in a spectral charge density of 6.3 ± 1.3 pC MeV −1 (full-width at half-maximum (FWHM) ± s.d.), with a mean horizontal divergence σ x ′ of 0.8 ± 0.2 mrad (r.m.s. ± s.d.) throughout a ±5% energy band (180)(181)(182)(183)(184)(185)(186)(187)(188)(189)(190)(191)(192)(193)(194)(195)(196)(197)(198). The electron-beam duration σ z can be estimated to be ~14.8 ± 1.6 fs (FWHM ± s.d.) based on previous measurements 43 . With the spectrometer removed, the electron beam is transported through the COXINEL beamline 56 . A triplet of tunable high-gradient quadrupoles (QUAPEVAs), located behind the LPA, first handle the electron-beam divergence for chromatic emittance growth mitigation. The beam is then decompressed in a four-dipole-magnet chicane. For a nominal chicane strength R 56 of −1.8 mm, the chicane stretches the beam up to 0.9 ps (FWHM), while imposing an energy-position correlation (chirp) according to γ(t) = γ 0 (1 + ct/R 56 ), where t is the longitudinal position along the beam (t < 0 corresponds to the head) with respect to the central-energy γ 0 location, and c is the speed of light. Subsequently, four quadrupoles create a chromatic sliding focusing 47 of the electrons according to their energy inside an in-vacuum undulator. This undulator consists of 97 periods of 20-mm length, with a gap tunable down to 4 mm, providing a maximum deflection parameter K u of 2.47. Electrons are finally deflected with a dipole, allowing for photon-beam diagnostics. The seed is generated by frequency-conversion of a small fraction of the driver laser, providing a pulse energy E seed of 0.8 μJ within a bandwidth Δλ seed of 3.9 nm (FWHM) at a central wavelength λ 0 of 269 nm. To relax the temporal overlap between the seed and electron beam, the seed is stretched to an estimated duration (ΔT seed ) of 1 ps (FWHM) by introducing dispersion. This stretching induces a strong longitudinal dependence (linear chirp) of the seed wavelength according to λ seed (t) = λ 0 + (t − τ)/D λ , where τ is the delay with respect to the electron-beam maximum charge-density location, and D λ is the group-delay dispersion. The radiation at the undulator exit is near-field-imaged onto a two-dimensional (2D) UV spectrometer, providing a 2D spatio-spectral distribution, that is, vertical position versus spectral distribution.

Seeded FEL demonstration
The measured spatio-spectral distributions are presented in Fig. 2a. The synchrotron radiation (SR) alone ( Fig. 2a(i)) exhibits a broadband spectral distribution due to the large electron-beam energy spread. The absence of narrowband spikes states that, in the present experiment, SASE cannot be observed due to the too low charge density of the electron beam. The seed radiation only (Fig. 2a(ii)) has a nearly Gaussian spatio-spectral distribution with a peak intensity approximately eight orders of magnitude higher than the synchrotron radiation. Once the 3D (spatial, temporal and frequency) overlap between the electrons and the seed is established inside the undulator (Methods), an additional redshifted signal appears (Fig. 2a(iii)). To ease its viewing, the seed contribution ( Fig. 2a(ii)) is subtracted (Methods), leading to the trace shown in Fig. 2a(iv). This isolated trace is spectrally redshifted by more than 5 nm with respect to the seed. The experimental spatio-spectral distributions (Fig. 2a) and on-axis spectral intensities detailed as lineouts in Fig. 2c are found to be in very good agreement with the simulations (Methods) shown in Fig. 2b. The isolated redshifted and over 750 m for beam energies above 5 GeV and sub-nanometre FEL wavelengths (SACLA 17 , Swiss-FEL 18 , LCLS 13 and E-XFEL 14 ). With their unprecedented accelerating fields, laser-plasma accelerators (LPAs) 19 have appeared as alternative drivers 20 , promising a downscaling in size by more than one order of magnitude. Thus, the realization of a compact LPA-driven FEL has been identified as one of the major challenges of this decade, as addressed by the European Plasma Research Accelerator with eXcellence In Applications (EuPRAXIA) 21 in the European Strategic Forum for Research Infrastructure (ESFRI) roadmap.
In FELs, the wiggling relativistic electron beam interacts with co-propagating radiation at the resonant undulator wavelength λ R = λ u × (1 + K 2 u /2)/(2γ 2 ), where γ is the Lorentz factor of the electron beam, λ u is the undulator period and K u is its deflection parameter. This interaction leads to an energy modulation, which is further converted into a density modulation of the electron bunch at λ R , initiating a coherent emission process scaling quadratically with the bunch charge. FEL radiation is spectrally tunable via the electron energy and the deflection parameter. In oscillator 22 and self-amplified spontaneous emission (SASE) 23 configurations, the radiation starts from shot noise. SASE FELs can provide gigawatt-level peak power pulses with a high degree of transverse coherence. However, they suffer from low longitudinal coherence because of this shot-noise starting point, generally exhibiting spiky temporal and spectral distributions. To mitigate these issues, external seeding was proposed 24,25 . In a seeded configuration, the initial radiation is an external coherent source or a monochromatized upstream SASE pulse tuned to λ R . Seeding thus accelerates the first energy exchange stage, but is also a powerful strategy to control the pulse shape and guarantee longitudinal coherence 26,27 , even down to very short wavelengths 7,12,25,28,29 . At present, most XUV and X-ray FELs can be externally seeded or self-seeded to provide the highest level of spectral purity 30,31 and the possibility to tailor emission properties 32,33 .
LPAs rely on ultrashort and relativistic-intensity laser pulses 2,34 focused into underdense plasma to excite micrometre-scale collective plasma oscillations, which travel at nearly the speed of light in the wake of the drive laser pulse. Unlike cavity-based accelerators, LPAs are not limited by vacuum breakdown, and their acceleration gradients can reach several hundreds of gigavolts per metre. LPAs have developed rapidly as a result of extensive research into high-quality injection and acceleration schemes 35 , plasma targets, drive laser technologies 36 and diagnostics 34 . They now feature electron bunches with optimized parameters at energies up to 8 GeV (ref. 37 ), emittances down to 0.1 mm mrad (ref. 38 ), sub-percent energy spread 39 and nanocoulomb charges 40,41 , with durations typically around 10 fs (refs. 42,43 ) and sustaining peak currents of several tens of kiloampères 40,43,44 , all with improved stability 45 .
LPAs are now setting the stage to drive smaller-footprint FELs. After the development of LPA beam manipulation strategies 46,47 and the observation of spontaneous emission 48-52 , the first SASE FEL amplification driven by an LPA was reported 53,54 at a wavelength of 27 nm. As SASE radiation still inherently lacks temporal coherence, in this Article we aim to experimentally demonstrate a seeded LPA-driven FEL. Using an external seed at 270 nm, we achieve control of the FEL-radiated wavelength, taking advantage of the energy and wavelength chirps of both the electron and the seed laser beams, respectively. Longitudinal coherence is substantiated by the observation of phase-locked interference fringes between the seed and the FEL pulses. These experimental results are supported quantitatively by both numerical simulations and analytical modelling.

Experimental set-up
The experiment was performed at the Helmholtz-Zentrum Dresden-Rossendorf (HZDR), combining the LPA driven by the 100-TW-class arm of the DRACO (Dresden Laser Acceleration Source) laser 55 with the COXINEL (COherent X-ray source INferred from Article https://doi.org/10.1038/s41566-022-01104-w trace shown in Fig. 2a(iv) evidences seeded FEL operation, following the prediction of ref. 58 .
The fundamental mechanism leading to this redshift is illustrated in Fig. 3. In a seeded configuration (Fig. 3a), the first step of the FEL process is energy exchange between the seed and electron beam at the resonance wavelength. As both the seed wavelength and the electron-beam energy are time-dependent, the resonant condition λ seed (t) = λ R (t) can only be met at one longitudinal position, t 0 ( Fig. 3b and Methods). This local energy exchange at t 0 leads to an energy and further density modulation of the electrons at λ seed (t 0 ) (or λ R (t 0 )), expected to be followed by a coherent emission at the same wavelength. However, if, at the scale of one modulation period, the electrons' energy varies substantially, which is the case due to the strong electron-beam chirp, the initial density modulation period is stretched by the dispersion experienced along the undulator. This leads to a lengthening of the coherent emission wavelength (Fig. 3c), that is, a redshift 58 . According to this model, the final seeded FEL wavelength is expected to behave as The electron beam generated in the LPA is first characterized using a removable electron spectrometer and then sent through a triplet of quadrupoles (QUAPEVAs) for beam transport to the undulator and FEL radiation generation. ICTs, integrated current transformers. Non-labelled elements: dipoles, red blocks; optical lenses, blue disks; mirrors, grey circled black disks. a, Particle-in-cell simulation rendering of the accelerating structure driven by the laser pulse (red); the electron cavity sheet formed from the plasma medium (light blue) is in purple and the accelerated electron bunch in green. b-d, Electron-beam transverse distribution measured at the LPA exit (b), the undulator entrance (c) and the undulator exit (d). Exp. Article https://doi.org/10.1038/s41566-022-01104-w where K u0 is the deflection parameter ensuring resonance at τ = 0, and L eff is the effective undulator length along which the modulation period stretching takes place. The isolated trace exhibited in Fig

Fig. 3 | Principle of seeded FEL and spectral control. a,
The seeded FEL principle: an external seed laser periodically modulates, at its optical wavelength, the electron beam as it travels in the periodic magnetic field of an undulator. The microbunched electron beam finally emits coherent light at the wavelength of the density modulation period. b, FEL resonance condition: due to the chirps of the electron-beam energy and the seed wavelength, energy exchange between the electron beam and the seed laser can only occur at the longitudinal position t 0 where the resonance condition λ seed (t 0 ) = λ R (t 0 ) is satisfied. This resonance location t 0 is shifted (orange arrow) if the delay τ between the seed and the electron beam is varied. c, Undulator dispersion-induced modulation period stretching. As long as the electron beam traverses the undulator with an average longitudinal speed Vz, the undulator dispersion induces a stretching of the electron beam. The periodic modulation initiated by the seed laser at the resonant wavelength is thus stretched, leading to a FEL coherent emission redshifted with respect to the seed-laser optical wavelength. d, λ FEL versus delay τ (Extended Data Fig. 2). τ = 0 corresponds to perfect synchronization between the seed and the electron beam. For τ < 0 (resp. τ > 0), the seed arrives before (resp. after) the electron beam at the undulator entrance. Experimental data are shown as grey dots, with the colour scale representing the charge of each single shot. The delay scan was carried out for a 4.3-mm-undulator gap. The model results are shown as a black dashed line, using equation (1) Fig. 3) using two sets of data, both recorded at the optimum gap (4.3 mm) and optimum delay (τ = +0.1 ps). The first set recorded is shown as blue dots and the second set, recorded 1 h later, as red dots. Simulated ξ FEL versus charge is shown using σ e = 5% (r.m.s.) with a total charge of 100 pC, that is, a spectral charge density of 3 pC MeV −1 (black diamonds) and σ e = 7.5% (r.m.s.) with a total charge of 100 pC, that is, spectral charge density of 2 pC MeV −1 (black stars), with other parameters as in Fig.   2. The quadratic fit of the simulated ξ FEL is shown as a black dashed line using the fit formula ξ FEL = a × charge, with a = 1.79 × 10 −5 (resp. 7.25 × 10 −6 ) for the first set (resp. the second set). b, FEL on-axis spectra corresponding to the ξ FEL points in a, using the red and blue colour scale according to charge. c, Difference between the FEL on-axis spectra (b) and the associated seed on-axis spectra. All experimental data were sorted according to the seed peak intensity, keeping only data for seed intensity in the ±10% range around the optimum FEL generation.

FEL spectral control
The measured λ FEL as a function of the delay τ is shown in Fig. 3d. Beyond τ = ± 1 ps, the FEL signal disappears. With the seed pulse longitudinally sweeping the electron-beam distribution, this ±1-ps interval is in good agreement with the convolution between two ~1-ps FWHM pulses (seed and electron beam). Within the observation range, λ FEL correlates linearly with τ, in good agreement with simulations, accurately following the prediction of equation (1). These results show that the FEL wavelength is locked thanks to the external seeding and can be fully controlled by the electron-beam and seed chirps.

Charge dependence
To further classify the FEL emission, a new observable is derived from the isolated trace shown in Fig. 2c(iv): the isolated FEL pulse energy, ξ FEL (Methods). Two sets of ξ FEL measurements are presented in Fig. 4a. For each set, the best ξ FEL shots at a given charge are consistent with a quadratic dependence versus beam charge. The first set is well-reproduced by simulations using a spectral charge density of 3 pC MeV −1 , and the second set, recorded 1 h later, is matched using 2 pC MeV −1 , indicating a slight detuning of the LPA performance, that is, a reduction of charge density over time. The shots below the driving quadratic behaviour are attributed to the intrinsic shot-to-shot jitter of the LPA beam, leading to a gain loss and/or to a spatial or spectral mismatch between the seed and the electron beam in the undulator. The upper-limit quadratic charge dependence is a signature of an FEL in the coherent emission regime.

Longitudinal coherence
In Fig. 4b, two sets of measured FEL spectra are shown. First, the FEL wavelength stays locked and is independent of the beam charge as predicted by equation (1). The spectra also exhibit a systematic periodic perturbation spectrally positioned between the seed and the FEL peak intensity (within the dashed rectangle). For a more thorough study, the seed contribution is removed from the FEL spectra (Methods), resulting in the Δ FEL trace shown in Fig. 4c. The perturbations unambiguously correspond to interference fringes between the seed and FEL pulses 58 . Over the two sets of measurements, both the period and the phase of those fringes remain stable. Such a stability can only be derived from phase-locking between the seed and the FEL pulses, providing conclusive evidence of temporal coherence.

Conclusion
We have demonstrated an LPA-driven seeded FEL. Its radiation is spectrally controlled and, in contrast to SASE, it exhibits a defined longitudinal phase correlation, adding temporal coherence to this compact light source. The continuous progress of the LPA beam quality, confirmed here, together with the accuracy of the demonstrator modelling, enables straightforward scaling of our results to the application-relevant XUV range. Considering a 400-MeV electron beam with parameters as described in ref. 41 , together with the current COXINEL beamline upgraded with a 3-m-long cryogenic undulator with a period of 15 mm (available at SOLEIL) and a seed generated by harmonics in gas, coherent FEL pulses above the gigawatt level are predicted at 40 nm (Extended Data Fig. 4). There is no showstopper for LPA-based seeded FELs down to XUV wavelengths. The path towards compact LPA-driven X-ray FELs remains challenging. Stringent electron-beam parameters have to be met, and higher-repetition-rate operation and system stability have to be improved further. Although these will be met by a large community effort over a long timescale, our findings represent a key milestone towards controlled, smaller-scale LPA-based FELs for applications benefiting from intrinsic laser-to-FEL pulse synchronization.

Online content
Any methods, additional references, Nature Research reporting summaries, source data, extended data, supplementary information, acknowledgements, peer review information; details of author contributions and competing interests; and statements of data and code availability are available at https://doi.org/10.1038/s41566-022-01104-w. Article https://doi.org/10.1038/s41566-022-01104-w

Laser system
The DRACO Ti:sapphire chirped pulse amplification system is a dual beam (1 PW and 100 TW) laser system 55 . The 100-TW system occupies a footprint area of ~50 m 2 hosted at the centre of the high-power radiation source, HZDR. The system delivers pulses of ~30-fs (FWHM) duration at a central wavelength of 800 nm. In the present experiment, only the 100-TW arm is used, delivering 2.1 J on target following a 6-m-long beamline to transport the laser beam from the compressor vacuum chamber to the electron experimental hutch. This hutch of ~70-m 2 area is under heavy radiation shielding and capable of supporting the LPA operating up to gigaelectronvolt energies as well as the COXINEL beamline. An off-axis parabolic mirror (f/20, focal length of 2 m) focuses the laser beam into the gas target, 2.5 mm above the nozzle. Before experiments, a wavefront sensor (PHASICS SID4) in closed loop with a deformable mirror provides focal-spot optimization, resulting in a spot size of 21 μm (FWHM) measured at the vacuum focus position, and yielding a normalized vector potential a 0 of 2.6. The spectral phase is measured with spectral-phase interferometry for a direct electric-field reconstruction (SPIDER-A.P.E.) in parallel with self-referenced spectral interferometry (WIZZLER-fastlite) in closed loop with an acousto-optic programmable dispersive filter (DAZZLER-fastlite) for correction of dispersion mismatch along the laser-amplifier and laser-beam transport chain. The LPA performance is further optimized by phase correction on the second-order (group-velocity) dispersion at DAZZLER. Active beam stabilization within the amplification system in conjunction with online diagnostics for laser near-field and far-field monitoring at the experimental area ensures shot-to-shot pointing stability.

LPA
The laser wakefield accelerator 19 is operated in a tailored scheme of the self-truncated ionization injection regime 59 detailed in ref. 57 . A 2.5-mm-diameter supersonic gas nozzle (SourceLAB SL-NOZ), mounted on a fast gas valve (Parker 9-series), provides the gas medium. The gas-jet profile is characterized with an interferometric method 60 , yielding a flat-top region of ~1.1 mm with a gas density of 1.4 × 10 18 cm −3 (resulting in a plasma density of 2.8 × 10 18 cm −3 ) and density ramps of ~0.5 mm on both sides along the laser-propagation axis. A low ionization threshold gas (He), ionized by the main laser-preceding pedestal, provides the plasma medium. K-shell electrons of a 1-vol% fraction high-ionization-threshold gas (N 2 ) are only ionized in the vicinity of the laser intensity peak, providing injected electrons that constitute the final electron beam. The injection time is limited by a confined injection volume, where the injection conditions are satisfied, governed by the laser and wakefield evolution 59 . This scheme nevertheless allows for injection of large quantities of charge, constituting a nanocoulomb-class accelerator where energy spread is minimized by beam loading 40 .

LPA beam characterization
The electron-beam spectrometer at the LPA exit consists of a 0.4-m-long permanent magnet dipole with a magnetic field strength of 0.9 T. Phosphor-based scintillating screens (CAWO-OG-16 FRONT), imaged onto 12-bit CMOS cameras (Basler acA2040-35gm), are positioned such that the energy resolution is optimized with point-to-point imaging 55 from 60 to 270 MeV. The absolute charge response of these scintillating screens was calibrated using the ELBE (Electron Linac for beams with high Brilliance and low Emittance) accelerator 61 . This broad-range spectrometer enables us to determine the electron-beam spectral distribution and divergence in the horizontal (that is, non-bending) axis plane. Being a destructive beam diagnostic, it can be inserted on demand into the beam path, but is removed for beam transport through the COXINEL beamline.

Beamline magnetic components
The COXINEL beamline starts with a triplet of high-gradient permanent-magnet-based quadrupoles with variable gradient (QUA-PEVAs) 62

Undulator
The radiation source is a planar in-vacuum hybrid undulator consisting of 97 periods of 20-mm length. This was built using NdFeB magnets and vanadium Permendur poles, and optimized at Synchrotron SOLEIL. Using a series type-C Hall probe and a rotating coil, the phase error and electron trajectory were optimized. The measured magnetic field B u (first harmonic) versus undulator gap g can be fitted according to

Electron-beam transport method
The magnetic elements and the diagnostics are aligned with a laser tracker and a theodolite on the laser axis using the main laser cross-shape references with an accuracy of ±0.025 mm. To transport the electron beam, a beam pointing alignment compensation (BPAC) method 56 relying on the transport matrix response is used to compensate for initial electron beam pointing or eventual misalignments of the QUAPEVAs magnetic axis. The position and dispersion along the line can be independently corrected, thanks to a modification of the QUAPEVAs magnetic centre via the translation tables on which they are mounted. Finally, the strength of the QUAPEVAs (by a modification of rotating cylindrical permanent magnets) is adjusted to correctly set the electron-beam transported energy. The electron beam transport along the COXINEL beamline can be simulated with BETA 65 and ELEGANT 66 codes (Extended Data Fig. 5).

Electron-beam diagnostics
Five electron-beam imagers are implemented along the beamline. They all consist of a scintillating screen, imaging optics and a camera. The screens are mounted on a motorized stage for on-demand insertion on the electron-beam axis and finally backside-imaged. The screen of the first imager (at the LPA exit) is a LANEX screen protected by 75-μm black ionized aluminium foil. It is imaged with a pair of simple focusing lenses onto a 12-bit charge-coupled device (CCD) camera (Basler acA640). The magnification ratio (0.12 and 0.17 resp. in the horizontal and vertical planes) together with the screen lead to a resolution of ~150 μm. All downstream imagers are equipped with a 16-bit CMOS camera (HAMAMATSU, ORCA Flash 4.0). The screen of the second imager (in the chicane) is a YAG:Ce screen protected by a 25-μm black ionized aluminium foil, and the imaging optics is a QIOPTIC custom objective, providing a resolution of ~4.7 μm in both planes. The screens of the third and fourth imagers (at the entrance and exit of the undulator) are YAG:Ce, and their imaging optics is a f/2 100-mm-focal-length ZEISS macro objective. The resolution is 6.0 μm (resp. 6.4 μm) in the horizontal (resp. vertical) plane at the undulator entrance and 6.5 μm (resp. 6.8 μm) in the horizontal (resp. vertical) plane at the undulator exit. The screen of the last imager (after the dump dipole) is a LANEX screen protected by a 25-μm black ionized aluminium foil, and the Article https://doi.org/10.1038/s41566-022-01104-w imaging optics is a f/2.8 105-mm-focal-length SIGMA macro objective. The resolution is 21 μm in both planes. Two absolute charge monitors, turbo integrating current transformers (ICTs) from Bergoz, are installed at the entrance ( just after the LPA chamber) and at the exit ( just after the undulator) of the beamline.

Seed
A small fraction of the LPA driver laser is extracted from its centre axis using a 1/2-inch pick-off mirror to generate the seed by frequency conversion. A half-λ plate combined with reflective thin polarizing plates allows step-less adjustment of the frequency conversion input energy from 0.05 up to 1.2 mJ. Frequency tripling is achieved using a set of two beta-barium borate crystals (type 1 SHG and type 1 THG) in combination with a group-velocity delay compensation plate and a dual waveplate (EKSMA femtokit). Discriminative spectral filtering for the frequency-tripled component is achieved using a dichroic mirror and propagation over nine laserline mirrors (262-266 nm; Thorlabs NB1-K04). A broadband spectrometer (Avantes StarLine AvaSpec, ILS2048CL-EVO) confirms no remaining fundamental or second-harmonic contributions in the final seed. The seed has a central wavelength of λ seed = 269 nm with a bandwidth of Δλ seed = 3.9 nm (FWHM), measured at the undulator exit (Fig. 2). To relax synchronization, the seed is stretched by introducing temporal dispersion. The total thickness of the FuSi optical elements is d = 59.9 mm. Taking into account the group-velocity dispersion of FuSi at 270 nm, D = −4,945.5 ps (nm km) −1 , the final group-delay dispersion is D λ = D × d = −0.296 ps nm −1 . In other terms, the seed laser pulse experiences a second-order dispersion D 2 = 1.146 × 10 4 fs 2 . Assuming an initial pulse duration of 30 fs (FWHM), being the Fourier limit, the final seed pulse duration is estimated to be ΔT seed = D λ × Δλ seed ≈ 1 ps (FWHM). Both ΔT seed and D 2 are used as input parameters for simulations. Spatial filtering is performed after frequency tripling using a lens (f = 922 mm) combined with a 210-μm-diameter ceramic pinhole. A second lens (f = 461 mm) collects the beam and projects a weak focus with a Rayleigh length of z R = 15 m and a waist located 5 m before the undulator entrance. The seed is injected into the COXINEL beamline using a flat enhanced aluminium mirror inserted into the middle of the chicane. Using a calibrated photodetector (Gentec PE10B-Si-D0), the seed energy is measured to be 0.8 μJ at the entrance and 0.5 μJ at the exit of the COXINEL beamline.

Photon-beam diagnostics
The main radiation diagnostics are located after the dump dipole at the end of the beamline. The radiation is collected by a pair of lenses: one plano-convex FuSi of focal length f = 400 mm followed by one plano-concave FuSi of focal length f = −200 mm. Depending on the distance between the two lenses, this optical system can image the radiation from the undulator entrance to the undulator exit onto a fixed image plane downstream. In this fixed image plane, two diagnostics can be implemented: a UV camera or a 2D spectrometer depending on the position of a final motorized enhanced aluminium mirror. The UV camera is an ORCA-II from Hamamatsu. The spectrometer is an iHR320 from Horiba/Jobin-Yvon equipped with a back-illuminated camera, providing the spectral distribution along the horizontal axis and the spatial distribution along vertical axis.

3D overlap adjustment
The interaction, that is, energy exchange, between the seed and the electron beam inside the undulator requires an overlap in three dimensions: space, frequency and time. Spatial overlap is achieved using the near-field imaging system on both the UV camera (for the horizontal) and the UV spectrometer (for the vertical) while steering both the seed and the electron beam. Because the distance between the two lenses of the imaging system can be remotely adjusted to change the object plane, the spatial overlap can be monitored all along the undulator. The frequency overlap is achieved using the spectrometer while tuning the undulator gap. Because both seed and electron beam originate from the same laser, they are inherently synchronized and free of jitter. The remaining delay τ is adjusted using a delay stage on the seed path while monitoring the arrival times of the seed and synchrotron radiation with a streak camera (Hamamatsu, FESCA-100). For this purpose, the seed and synchrotron radiation can be extracted at the undulator exit using a removable aluminium mirror, and further focused using a FuSi lens (f = 1 m) into the streak camera entrance slit. Seed and synchrotron radiation pulses are simultaneously observed in single-shot while adjusting the delay stage on the seed path, until the temporal overlap falls beyond the accessible resolution (~500 fs).

FEL simulation
The spatio-spectral distribution of the FEL at the undulator exit is simulated in four steps. In a first step, a 6D Gaussian electron-beam distribution with 10 6 particles is generated using a set of r.m.s. values for beam position, divergence, energy spread and duration and giving a total bunch charge. In the second step, this 6D distribution is transported down to the undulator entrance with BETA code, using a chromatic matching lattice set at 188.8 MeV. Transporting with this code or ELEGANT is equivalent (Extended Data Fig. 6). The 6D distribution obtained at the undulator entrance is longitudinally sampled into 2,000 slices, and each slice is described by the six r.m.s. values of its envelope. The duration of one slice is 4 × λ seed , that is, 3.6 fs. In parallel, the seed is simply modelled in the frequency domain according to its central wavelength λ seed of 269 nm, bandwidth Δλ seed of 3.9 nm (FWHM) and group-delay dispersion D λ of −0.296 ps nm −1 . After Fourier transforming, the seed pulse in the time domain is sampled into 2,000 slices, and each slice is described by its peak power and phase. In the third step, both the seed and the electron-beam longitudinal distributions are loaded into GENESIS 67 code to simulate the radiation generation process along the undulator. The result of this simulation is the 3D (x, y, t) electric field at the undulator exit, with x (resp. y) the coordinate along the horizontal (resp. vertical) plane and t the longitudinal (time) coordinate. Using standard Fourier optics, the 2D (x = 0, y, t) field distribution is finally converted into the 2D (y, λ) spatio-spectral distributions illustrated in Fig. 2. The simulated spatio-spectral distributions can be compared directly to the spatio-spectral distribution recorded on the UV spectrometer.

FEL analytical modelling
The FEL emission is observed to be redshifted with respect to the seed wavelength. This redshift, Δλ FEL , can be attributed to a stretching of the initial density modulation (at λ seed ) along the undulator and is proportional to the undulator and chicane dispersion ratio according to 58 However, this simple formula does not take into account the time dependence of the electron-beam energy as well as the dispersion of the seed laser pulse. After passing through the chicane, the energy of the electrons mc 2 γ(t) is linearly correlated to their longitudinal position t according to where t is the longitudinal position along the beam with respect to the central energy mc 2 γ 0 . Due to the dispersion introduced by the optical elements, the seed laser is chirped and the instantaneous seed wavelength also depends on t according to Article https://doi.org/10.1038/s41566-022-01104-w where λ 0 is the seed central wavelength and τ is the relative delay between the seed laser pulse and the electron beam.
To fulfil the undulator resonance condition, the FEL interaction can only occur at the longitudinal position t 0 where that is, at Taking into account the time dependence of the undulator resonance condition in equations (2)-(4) permits us to refine the expression of the redshifted FEL emission: as a function of the relative delay τ between the seed laser and the electron beam.

FEL data analysis
Both the measured and simulated raw FEL data correspond to a single-shot 2D spatio-spectral distribution at the undulator exit. Experimental images correspond to the UV-spectrometer records using the near-field imaging system, whereas the simulated images correspond to the Fourier transform of the 3D electric field simulated by GENESIS. From those images, ξ FEL and λ FEL are systematically extracted as follows.
Each measured image is processed to remove the camera sensor offset and the hot pixels from Bremsstrahlung radiation. A preliminary record of the synchrotron radiation signal alone, that is, without seed, enables us to identify the vertical position of the expected FEL signal, which defines the y = 0 position. The FEL spectral profile I FEL (λ) is then obtained from vertical integration over a region of interest of ±6 pixels (corresponding to ±156 μm) around y = 0 and is normalized to its maximum value. The reference seed spectral profile I seed (λ) is deduced from the same image, integrating similarly the signal over the same pixel range but 30 pixels away from y = 0, and then normalizing to the maximum value. Each simulated image is treated exactly the same way to extract both the FEL and seed simulated spectral profiles.
The following process is then applied to both the measured and simulated spectral profiles. The FEL signal-to-noise ratio, SNR FEL , is defined as SNR FEL (λ) = I FEL (λ) − I seed (λ) I seed (λ) (8) and fitted with a Gaussian function for an accurate retrieval of the FEL wavelength, λ FEL (the location of maximum SNR FEL along λ). The FEL differential signal, corresponding to the FEL spectra with seed subtraction, is defined as ∆ FEL (λ) = I FEL (λ) − I seed (λ) (9) and its integral within the spectral interval [λ 1 = 239 nm; λ 2 = 279 nm] gives that is, the energy (in arbitrary units) of the isolated FEL pulse.

Commissioning
The COXINEL beamline was initially installed in the Salle Jaune of the Laboratoire d'Optique Appliquée (LOA). Using the LPA beam driven by the Salle Jaune laser system, electron-beam transport methods, the generation of undulator radiation, seed generation and shaping, and beam diagnostics were extensively tested and optimized 52,56 . Various methodologies to achieve the 3D overlap between the seed and electron beam, standard techniques on conventional radiofrequency accelerators but with adjustments for the specific LPA environment, were also tested. The experiment was then moved to HZDR, whose LPA allows the production of the higher charges that are required to demonstrate seeded FEL operation. A new undulator was built, and beamline components such as QUAPEVAs were modified and adapted for the HZDR experiment.

Data availability
All data are available upon reasonable request from the corresponding author.

Code availability
Codes used in this study are available upon reasonable request from the corresponding author.
Article https://doi.org/10.1038/s41566-022-01104-w Extended Data Fig. 1 | Electron beam properties at the entrance of COXINEL beamline. (a) the charge distribution of several sets of sequential shots at different times over two experimental days. No discrimination or sorting for performance is applied. (b) the mean RMS divergence and mean charge density evaluated for the ± 5% energy range (180-198 MeV) around the COXINEL design central energy (189 MeV) for all shots from a). Selecting shots considered to be of sufficient quality to contribute to FEL amplification, with a mean charge density > 4 pC/MeV throughout the abovementioned energy range (indicated by dashed box), selects 60% of all shots, consistent with experimental observations on FEL amplification signal probability per shot. Considering selected shots, a mean charge density of (6.3 ± 1.4 s.d.) pC/MeV with a mean RMS divergence of (0.80 ± 0.17 s.d.) mrad is found.