Halide-guided active site exposure in bismuth electrocatalysts for selective CO2 conversion into formic acid

It remains a challenge to identify the active sites of bismuth catalysts in the electrochemical CO2 reduction reaction. Here we show through in situ characterization that the activation of bismuth oxyhalide electrocatalysts to metallic bismuth is guided by the halides. In situ X-ray diffraction results show that bromide promotes the selective exposure of planar bismuth surfaces, whereas chloride and iodide result in more disordered active sites. Furthermore, we find that bromide-activated bismuth catalysts outperform the chloride and iodide counterparts, achieving high current density (>100 mA cm–2) and formic acid selectivity (>90%), suggesting that planar bismuth surfaces are more active for the electrochemical CO2 reduction reaction. In addition, in situ X-ray absorption spectroscopy measurements reveal that the reconstruction proceeds rapidly in chloride-activated bismuth and gradually when bromide is present, facilitating the formation of ordered planar surfaces. These findings show the pivotal role of halogens on selective facet exposure in activated bismuth-based electrocatalysts during the electrochemical CO2 reduction reaction. Bismuth is a promising catalyst for formic acid production from CO2 electroreduction, but its active site and phase under operation remain elusive. Now, a series of bismuth oxyhalide nanoplatelets has been evaluated using in situ techniques during the electrochemical CO2 reduction reaction, revealing insights about the active bismuth phase.

The electrocatalytic conversion of CO 2 into chemicals and fuels is considered as a powerful tool to store intermittent renewable energy in chemical bonds [1][2][3][4] . However, there remain several challenges that need to be faced before the full potential of electrocatalytic CO 2 conversion can be used. Among these challenges, a lot of research has been devoted to the optimization of three key descriptors of catalysis, that is, selectivity, activity and stability [5][6][7][8][9] . Despite the fact that C 2+ products (for example ethylene and ethanol) have a greater industrial value than C 1 products (for example carbon monoxide (CO) and formic acid (HCOOH)), the complicated reaction mechanism for C 2+ products hampers the development of selectivity and activity 10 . Furthermore, recent techno-economic analysis suggests that the synthesis of CO or formic acid as a base chemical is economically and practically more feasible due to the high production rate and superior adaptability to future industrial implementation compared to C 2+ products [11][12][13] . In numerous chemical processes, including electrowinning, leather tanning and aviation de-icing, formic acid has been extensively investigated as chemical feedstock [14][15][16] with a sizeable economic market 17,18 .
Over the past decades, efforts have been aimed at the optimization of electrocatalysts for HCOOH production 19 . Post-transition-metal-based electrocatalysts, like tin (Sn), indium (In), bismuth (Bi) and lead (Pb), have been extensively investigated as the typical catalysts for selective CO 2 to HCOOH electrochemical conversion due to their strong adsorption of the key intermediates towards formic acid production and suppression of the competing hydrogen evolution reaction 15,[20][21][22] . Among the post-transition metals, Article https://doi.org/10.1038/s41929-023-01008-0 Figure 1a depicts a typical BiOX layered structure. Through weak van der Waals interactions, the neighbouring halogen layers in the BiOX stack and the [Bi 2 O 2 ] 2+ slab are sandwiched between two layers of halogen atoms 42 . The studied BiOBr (BOB), BiOCl (BOC) and BiOI (BOI) catalysts were prepared through hydrothermal synthesis (see Methods). To determine the crystal phase and electronic structure of the obtained materials, XRD and X-ray absorption near edge spectroscopy (XANES) were employed. As shown in Fig. 1b, a typical layered BiOCl structure is observed with (001), (002) and (003) planes dominating the XRD pattern of BOC. The XRD patterns for BOB and BOI show similar layered structures, with the reflections slightly shifted to smaller diffraction angles due to the size of the halogen. Similar to BOC, a series of {001} facets dominates the XRD patterns, with negligible reflections of other facets. In Fig. 1c, the XANES spectra of the studied BOB, BOI and BOC are compared with those of reference metallic Bi powder and Bi 2 O 3 . BOB, BOI and BOC show a similar shape of XANES spectra, suggesting a shared electronic structure for Bi. It is clear that the Bi L 3 -edge position of the studied materials differs from that of metallic Bi, but closely resembles that of Bi 2 O 3 . This is further confirmed by the first derivative of the XANES spectra ( Supplementary Fig. 1), showing that the studied BOB, BOI and BOC have a similar oxidation state to Bi 2 O 3 , suggesting the presence of Bi 3+ .

Structural characterization of bismuth oxyhalide nanoplatelets
To gain more insights into the structure of the prepared Bi-based catalysts, morphological structure and elemental distribution were investigated using scanning electron microscopy (SEM), high-angle annular dark-field scanning transmission electron microscopy (HAADF-STEM) and coupled STEM energy dispersive X-ray spectroscopy (STEM-EDS) measurements. The representative SEM images in Supplementary Fig. 2 show that all BiOX materials have a layered morphology, which is consistent with the XRD results. BOB has an irregular film structure that ranges in lateral size from 200 nm to 3 µm. This is similar to the morphology of BOI, which also exhibits an irregular film structure with smaller lateral dimensions, ranging from 100 nm to 300 nm. In BOC, uniform squares are observed with edge length around 1 µm. We hypothesize that BOC grows more isotropically due to the stronger Bi-Cl bonds 43 , compared to the Bi-Br and Bi-I bonds, similar to the growth mechanism for other two-dimensional compositions 44 . The lower bond energy makes it energetically favourable for BOB and BOI to grow anisotropically based on the layered crystal structure, whereas in BOC additional Bi-Cl bonds are created by growing thicker two-dimensional structures. The high-resolution HAADF-STEM image of BOI is shown in Supplementary Fig. 3, confirming its crystalline structure, whereas the HAADF-STEM image (Fig. 1d), along with the corresponding combined elemental maps (Fig. 1e) and EDS spectrum ( Supplementary Fig. 4), confirms the homogeneous distribution of Bi, O and I in the particles. From the high-resolution HAADF-STEM images and the corresponding Fourier transform (FT) patterns of BOB particles ( Supplementary Fig. 5), two different lattices could be observed in the bulk and edge area of the BOB particles. These lattices were identified as typical BiOBr and Bi 2 O 2 CO 3 , respectively. The presence of Bi 2 O 2 CO 3 at the surface is attributed to inevitable air exposure during sample transport. Similar to BOI, uniform elemental distribution of Bi, O and Br/Cl is observed in BOB/BOC, respectively (Supplementary Figs. [6][7][8][9]. The morphology and thickness of the studied materials were further investigated using atomic force microscopy (AFM). In BOB ( Supplementary Fig. 10), overlapping irregular layers are observed with thicknesses ranging from 70 to 90 nm, confirming the layered structure. BOI has a similar irregular layered structure, but its thickness is estimated to be around 40-50 nm ( Fig. 1f and Supplementary  Fig. 10c). BOC, on the other hand, is much thicker than both BOB and BOI, with a regular square shape and an approximate thickness of 600 nm ( Supplementary Fig. 11).
Sn and In have been studied extensively due to their low costs, relative abundance and easy processability. Due to toxicity reasons, Pb is not vastly studied for electrochemical CO 2 conversion, but has shown promise in combination with Cu for selective CO production 23 . Bi-based electrocatalysts for CO 2 conversion were first reported in 1995, but since then research into Bi-based electrocatalysts has stagnated 24,25 . Recently, Bi-based electrocatalysts have received increasing attention because of the low toxicity and high abundance of Bi (refs. 26,27). However, there is still a lot of room for improvement in terms of activity, selectivity and stability of Bi-based electrocatalysts 28 .
Various strategies, such as the use of nanostructures, defects and selective facet exposure, have been investigated to boost the selectivity and activity of electrocatalysts. However, the actual active site, stability and reaction mechanism under operating conditions are still up for debate 29 . By employing in situ attenuated total reflectance infrared spectroscopy to observe the unaltered oxide layer on the Bi surface, Pander et al. concluded that Bi is an oxide-independent electrocatalyst, although other researchers found the Bi-O interaction to be crucial for the effectiveness of Bi-based electrocatalysts in the electrochemical CO 2 reduction reaction (eCO 2 RR) 30,31 . Along with the debate regarding the participation of oxide species, density functional theory findings have suggested that the basal Bi(003) plane is less active than the edge plane Bi(012) in HCOOH formation 31 , while some other work stated that basal sites are more active 15,[32][33][34] . Furthermore, it has been reported that the use of layered metallic Bi electrocatalysts is beneficial in the eCO 2 RR since the layered structure often results in improved performance [35][36][37][38][39] . Identification of the active sites and disclosure of the restructuring during operation are crucial in the study of the Bi-catalysed eCO 2 RR in order to logically design a catalyst with improved activity, selectivity and stability to satisfy the requirement of practical applications. X-ray radiation is ideally suited for this purpose, because it can probe structural features over multiple length scales, depending on the X-ray technique of choice. However, online monitoring of structural changes and distinguishing between the sites responsible for the CO 2 conversion reaction require dedicated in situ X-ray characterization cells due to the attenuation of X-rays by the aqueous electrolyte 40,41 .
In this Article, layered {001}-oriented Bi oxyhalide (further denoted as BiOX, with X = Cl, Br or I) nanoplatelets were synthesized and used as a platform to in situ monitor the structure and active sites of Bi-based electrocatalysts in the eCO 2 RR. Through in situ X-ray diffraction (XRD) and in situ Raman spectroscopy measurements, we followed the dynamics of the in situ transformation of the prepared BiOX catalyst materials into activated metallic Bi electrocatalysts. It was found that the in situ-activated Bi electrocatalysts selectively exposed specific facets during catalysis, guided by the choice of halide: Brpromoted Bi(003) exposure and Clresulted in dominant Bi(012) facets, whereas Icreated a mixture. Furthermore, we linked the facet exposure to catalytic performance. BiOBr (BOB) exhibited a maximum HCOOH selectivity of 91% with a current density of 148 mA cm -2 at -1.05 V versus reversible hydrogen electrode (RHE). At a similar potential of -1.09 V versus RHE, BiOCl (BOC) displayed 69% HCOOH Faradaic efficiency (FE) at 88 mA cm -2 current density. BiOI (BOI) demonstrated a HCOOH selectivity of 76% at -1.08 V versus RHE with a current density of 95 mA cm -2 , between BOB and BOC. This suggests that the in situ-formed basal Bi(003) facet is more catalytically active than the stepped Bi(012) site in the eCO 2 RR. In addition, in situ X-ray absorption spectroscopy (XAS) measurements revealed that the reconstruction of BOC proceeded rapidly after reduction onset, as indicated by the short-lived transition state, while the transition state in BOB and BOI persisted longer. This implies that halogens in BiOX affect the selective facet exposure of the formed Bi during catalysis by tuning the reconstruction rate. This work provides further insight into the active sites and structural evolution of Bi-based electrocatalysts in electrocatalytic CO 2 conversion and paves the way for the rational design of electrocatalysts for liquid fuel production through in situ characterization studies. Article https://doi.org/10.1038/s41929-023-01008-0

Halide influence on eCO 2 RR performance
The electrocatalytic performance of the BiOX electrocatalysts in the eCO 2 RR was first explored using an H-type cell with a typical three-electrode configuration in 0.1 M KHCO 3 aqueous electrolyte (see Methods). This concentration for the electrolyte was chosen in this work because it allowed for direct comparison between different studies into the structure-performance relationships for electrocatalysts 45 and the potentials reported were automatically corrected to account for the uncompensated solution resistance (iR) 46 . Linear sweep voltammetry measurements were employed to estimate the activity of the studied catalyst materials. In Supplementary Fig. 12, the current densities for these three catalysts in the CO 2 -saturated electrolyte are plotted and it is observed that all current densities are larger than the corresponding current density in the N 2 atmosphere, indicating their intrinsic activity for the eCO 2 RR. Besides, BOB has a larger current density difference in CO 2 and N 2 than BOI and BOC, while the difference between BOI and BOC is minor, indicating that the activity of BOB in the eCO 2 RR is better than that of BOI and BOC. To analyse the selectivity of different eCO 2 RR products under various potentials, we have applied stepped-potential electrolysis across a potential range from -0.85 to -1.25 V versus RHE and detected the gaseous products with online gas chromatography and liquid products with offline NMR after around 40 min of eCO 2 RR. We can see, from Supplementary Fig. 13, that the FE of BOB for HCOOH is higher than 80% over the entire potential region and it reached up to 96% from −0.95 to −1.15 V versus RHE in the H-type cell, with effective suppression of the hydrogen evolution reaction and CO production. BOI had a maximum HCOOH FE of 85% at −1.15 V versus RHE, slightly lower than BOB, while BOC displayed a maximum HCOOH FE of 81% at −1.05 V versus RHE. After prolonged operation (up to 8 h), the selectivity for all BiOX electrocatalysts investigated degraded to 60% ( Supplementary Fig. 14) and the production of H 2 increased over time.
To evaluate the electrocatalytic CO 2 conversion performance of the as-prepared BiOX materials at current densities as close as possible Article https://doi.org/10.1038/s41929-023-01008-0 to industrial relevance 47 , a gas diffusion electrode (GDE) flow cell was used with 1 M KHCO 3 solution as the electrolyte. To account for the change in solution resistance, the potentials in the GDE cell were manually iR-corrected 46 . Within the GDE cell configuration (Supplementary Fig. 15), continuous gaseous CO 2 feedstock could be supplied through the porous carbon support to the catalyst surface so that the gas solubility limitation in the aqueous electrolyte was circumvented. On the other side of the porous electrode, electrolyte flowed over the catalyst surface with the help of a peristaltic pump, hereby diluting the HCOOH accumulation at the catalyst surface and buffering the electrolyte pH change, in order to minimize the mass transfer limitations. The minimization of mass transfer limitations was confirmed by the fact that the current densities using the GDE flow cell were 60 times higher than using the H-type cell (Supplementary Figs. 12 and 16). Figure 2a,b indicates that not only does the selectivity for BOB reach a maximum around -1.05 V versus RHE, but also the production rate of BOB outperforms the other two compositions in the investigated potential range. Current density is commonly used as the main indicator to evaluate catalyst activity. BOB has the highest total current density over the applied potential window of the studied catalysts, as shown in Supplementary Fig. 17. When solely HCOOH FE is considered, there is a large difference in partial current density between BOB, BOI and BOC ( Fig. 2c). At an applied potential of −1.05 V versus RHE, a HCOOH partial current density of 148 mA cm -2 is achieved for BOB, whereas BOI and BOC only reach 95 and 88 mA cm -2 at −1.08 V versus RHE and −1.09 V versus RHE, respectively. Different morphological features are known to result in different catalytic behaviour and larger specific surface areas usually expose more active sites 48 . In order to accurately define the contribution of the nature and number of active sites during electrolysis, we evaluated the electrochemical surface area (ECSA) of the as-prepared and spent catalysts by measuring the double-layer capacitance (C dl ) in the non-Faradaic potential area in an H-type cell   49 . Before catalysis, BOC had twice the double-layer capacitance of BOB and BOI, but after catalysis all investigated catalysts showed similar values. Considering that BOC resulted in lower selectivity and activity than BOB and BOI, we conclude that the larger ECSA did not contribute much to catalytic performance. Besides, the catalyst structures underwent reconstruction during catalysis, resulting in similar ECSA after catalysis. This is also supported by electrochemical impedance spectroscopy ( Supplementary Fig. 23). It can be seen that BOB, BOC and BOI have a similar semicircle in the high frequency area at the open circuit potential (OCP), implying a similar charge transfer property. When a reaction potential was applied, they all formed a second semicircle, which is the signal of the generation of a second interface, suggesting the structure of the catalysts studied changed at such a potential. This can be further confirmed by their SEM images before and after catalysis ( Supplementary  Figs. 24-26).

Halide-dependent reduction through in situ Raman spectroscopy
Based on the observations above, we have used in situ techniques to monitor the structural evolution of the catalyst materials under reaction conditions and to elucidate the relationship between catalyst reconstruction and catalytic activity. In situ Raman spectroscopy measurements were performed at a rate of 10 s per spectrum. As shown in Supplementary Fig. 27a, BOB exhibits BiOBr characteristics at the start of the reaction (A 1g Bi-Br band at 110 cm -1 and E g Bi-Br band at 158 cm -1 ) and these characteristics all fade away after 80 s at a fixed applied potential of -1.15 V versus RHE (ref. 50). The peak at 384 cm -1 is attributed to the E g and B 1g bands produced by the motion of oxygen atoms 51 Supplementary Fig. 27c), similar to BOB. We note that these vibrational features for the Bi-halide bonds confirm that Bi-Cl forms the strongest bond, supporting our hypothesis that the bond strength determines the growth dynamics of the BiOX structures. However, the Bi-O band persists in BOC even after 210 s ( Supplementary Fig. 30), indicating that the reduction of BOC is hampered compared to those of BOB and BOI (ref. 55). This implies that reconstructions occur in the pristine Bi oxyhalides during catalysis and the conversions of BOB and BOI are easier than that of BOC under the same applied cathodic potential. The relatively poor reducibility of BOC can be attributed to the larger size and thickness than the other Bi oxyhalide nanoplatelets 56 . Due to detection limitations and a low signal-to-noise ratio, it is difficult to see other formed species, such as reaction intermediates, during catalysis using in situ Raman spectroscopy.

Halide-guided active site exposure through in situ XRD
Dynamic structural information was obtained by performing in situ XRD measurements to reveal the structure evolution during catalysis. The time-dependent in situ XRD pattern was collected every 3 min, except for the first two XRD patterns (that were collected each minute) in order to catch the small changes at the beginning of the reaction. In Fig. 3a and Supplementary Fig. 31a, it can be seen that BiOBr {001} facets dominate in BOB at the OCP, which quickly fade away within 7 min at an applied potential of −1.15 V versus RHE (intensity versus time trace in Fig. 3d), while reflections of metallic Bi (PDF # 00-004-1246) begin to appear after 1 min already with dominant arrangements of Bi(003) and Bi (006)   Article https://doi.org/10.1038/s41929-023-01008-0 distinct characteristic BiOI reflections can be seen in BOI (Fig. 3b and Supplementary Fig. 31b) at the start of the reaction, which also disappear in the first 4 min according to the intensity versus time trace (Fig. 3e). Simultaneously, Bi(003) and Bi(006) appear in the XRD patterns, with the same contributions from Bi(012), Bi(104) and Bi(110) facets located at 27.1, 37.9 and 39.6°, respectively. Furthermore, BOC exhibits BiOCl peaks at the start of the reaction, which gradually decline during catalysis ( Fig. 3c and Supplementary Fig. 31c). Furthermore, no Bi(003) and Bi(006) reflections are observed for BOC after 40 min of cathodic bias, evidenced by the intensity versus time trace (Fig. 3f). These in situ time-dependent XRD measurements indicate that an applied potential of -1.15 V versus RHE is sufficient driving force to reduce BOB and BOI, whereas for BOC higher applied potentials are required. Since the studied catalyst materials have shown potentialdependent catalytic performance (Fig. 2a), potential-dependent in situ XRD was also conducted to reveal the structure evolution as a function of applied potential, in which a diffraction pattern was collected every -0.20 V versus RHE. Figure 4a,d and Supplementary Fig. 32a illustrate the same trend as the result in time-dependent measurements, with BOB showing characteristic BiOBr reflections at the OCP and converting into metallic Bi at the cathodic potential onset of −0.15 V versus RHE. This is consistent with the cyclic voltammetry (CV) result (Supplementary Fig. 18), in which the two reduction peaks of Bi 3+ /Bi are located at potentials of −0.02 V versus RHE and −0.15 V versus RHE. The BiOBr reflections fully disappear at an applied cathodic bias that is a bit more negative than that given by the CV result (<-0.15 V versus RHE). A possible reason for this is that CV mainly measures the surface redox properties, whereas XRD detects structural changes of the bulk electrode. As the potential-dependent catalysis proceeds, Bi(003) and Bi(006) facets remain the main exposed facets for the BOB-derived electrocatalysts. Likewise, BOI also shows typical BiOI reflections at the OCP (Fig. 4b,e and Supplementary Fig. 32b), but with increasing negative potentials these peaks gradually decrease in intensity. Metallic Bi peaks already appear at a potential of −0.15 V versus RHE, which is also in agreement with the CV result for Bi 3+ /Bi reduction at this potential. Furthermore, this result indicates that the reducibility of BOI is higher compared to that of BOB, since the characteristic BOI reflections have faded out at a lower cathodic bias. A similar intensity of Bi(003), Bi(006) and Bi(012) facets is observed in BOI during catalysis, just as in the time-dependent in situ XRD measurements (Fig. 3b). This indicates that the activated Bi catalyst has the same conformation regardless of time-or potential-dependent electrocatalytic activation. Figure 4c,f and Supplementary Fig. 32c show the in situ XRD patterns of BOC at different potentials. BiOCl reflections are observed at the OCP and they gradually fade away when larger cathodic potentials are applied. The most striking difference between BOC and BOB/BOI is that the Bi(012) facet is the most pronounced in BOC during catalysis, along with the less pronounced Bi(104) and Bi(110) facets, while Bi(003) and Bi(006) are effectively suppressed. The reflections of BiOCl remain at the applied cathodic bias of −1.35 V versus RHE. This is consistent with the observation in the CV curve for BOC activation that the Bi 3+ /Bi reduction peak requires a more negative potential compared to BOB and BOI. As mentioned above, this could be due to the relatively large thickness of BOC, which normally requires more driving force to be fully reduced. The observed residue of BiOCl is attributed to the uneven catalyst layer on the glassy carbon wafer, as the drop-casting method was used to prepare the electrode. Results of the ex situ grazing incidence XRD (GIXRD, Supplementary Fig. 33) measurement, which was used to determine surface structure, confirm that all of the studied BiOX materials have been reduced to metallic Bi surfaces after catalysis. In addition, on the surface of the spent BOB, only Bi(003) can be observed, while on the surface of the spent BOC, Bi(012) dominates and on the surface of the spent BOI, both facets can be observed. From these results, it is inferred that Bi(003) and Bi(012) facets contribute differently to the electrochemical CO 2 conversion reaction, with Bi(003) resulting in superior formic acid production. Considering their catalytic performance in terms of activity and selectivity (Fig. 2), we conclude that in the studied in situ-activated Bi catalyst system, the in situ-formed Bi(003) facet is more catalytically active than Bi(012). Article https://doi.org/10.1038/s41929-023-01008-0 Furthermore, we conclude that bromide promotes exposure of the active Bi(003) surface sites, whereas chloride results in preferred exposure of a less-active Bi(012) surface. Iodide has a less profound influence on the facet exposure, resulting in equal contribution of Bi(003) and Bi(012) and intermediate performance for formic acid production.

Halide-guided reconstruction rates through in situ XANES
To further investigate the dynamic electronic structure of the studied BiOX catalysts during catalysis, in situ XANES was used under time-dependent and potential-dependent conditions (time resolution 2 min per spectrum). The measurement spot in the in situ XANES measurement was 1 × 1 µm and this was moved around during catalysis in order to minimize possible beam-damage effects. In Fig. 5a, BOB shows a typical BiOBr XANES spectrum at the OCP. When a cathodic bias of −1.15 V versus RHE is applied, the Bi L 3 -edge gradually moves to the lower energy region and the shape of the XANES curve starts changing, indicating restructuring and a change in oxidation state. As a function of time, the Bi L 3 -edge moves close to the edge energy of metallic Bi (13,419 eV), suggesting that BOB is being gradually converted into the metallic Bi phase under the reaction conditions. A similar trend is observed for BOI and BOC , in which the Bi L 3 -edge also gradually shifts to lower energy towards the edge position of metallic Bi. Next, we turn to the observation of BiOX reconstruction towards metallic Bi during catalysis. The rate of the structure transformation varies depending on the halide. The difference in rate of reconstruction can be seen more easily in the heat maps of the first derivative of the XANES spectra. It can be seen that the structure evolution has an earlier onset in BOI (4 min, Supplementary Fig. 34) and BOB (4 min, Fig. 5b), compared to BOC (8 min, Supplementary Fig. 35). This is in line with the in situ XRD and Raman spectroscopy measurements discussed above. In addition, the transition state (that is the mixture of BiOX and metallic Bi phase) of structure reconstruction persists longer in BOB, in contrast to BOI and BOC in which the transition state disappears faster (Fig. 5c).
Through linear combination fitting (LCF), the dynamic composition change during catalysis can be better quantified. Supplementary   Fig. 37 shows the LCF example of BOB in 12 min. In Fig. 5c, the LCF analysis was applied to the time-dependent in situ XANES spectra, with Bi powder and BiOX as reference materials. It becomes evident that the structural evolution (BiOBr < 90% and Bi > 10%) has an earlier onset in BOI and BOB than in BOC at an applied potential of -1.15 V versus RHE, that is 4 min, 4 min and 8 min, respectively. The difference in onset time compared to the in situ XRD and Raman spectroscopy measurements could be due to the difference in their detection accuracy and signal-to-noise ratio, whereas the overall trend is unaffected by the choice of characterization technique. The transition state is defined as the intermediate state between the two stable reference states: pristine Bi oxyhalide and metallic Bi. The transition state is determined to last for 14 min in BOB, while full transformation from pristine Bi oxyhalide to metallic Bi is achieved in 6 min for BOI and BOC.
In the potential-dependent in situ XANES spectra, the same trend can be found: the onset potential for BOB and BOI is lower than for BOC. In Fig. 5d, no obvious change in the Bi L 3 -edge of BOB is observed upon changing the applied potential from the OCP to −0.35 V versus RHE, but the edge shifts to lower energy at −0.55 V versus RHE and onwards. Upon scanning the potential more negative, both the shape and edge position become similar to that of metallic Bi. Likewise, BOI has a structure evolution onset potential at −0.35 V versus RHE and quickly turns into a metallic-like structure at higher cathodic bias (Supplementary Fig. 38). On the contrary, BOC seems to be more difficult to be converted into the metallic counterpart, evidenced by the delayed reconstruction onset potential at −1.35 V versus RHE ( Supplementary  Fig. 39). In BOB, the transition state persists in a larger potential window, in contrast to that in BOI and BOC (Fig. 5e and Supplementary  Figs. 38-40). The different onset (time and potential) of the BiOX reconstruction could be attributed to their different thickness and size: the larger and thicker BOC needs more driving force to initiate restructuring than BOB and BOI. However, after the reconstruction onset, the lifetime of the transition state seems to play an important role in tuning the Bi facet exposure during catalysis, which is guided by the presence of the halide. Article https://doi.org/10.1038/s41929-023-01008-0 The LCF results of the potential-dependent in situ XANES spectra are shown in Fig. 5f. The onset potential of structure evolution in BOB is identified to be −0.55 V versus RHE and the transition state is found in the range −0.55 to −0.95 V versus RHE. In BOI, the potential window where the transition state could be discerned ranges from −0.35 to −0.75 V versus RHE, while in BOC the restructuring occurs at −1.35 V versus RHE. In addition to the different size of the pristine BiOX, the onset of structure evolution during catalysis can also be explained by the hard-soft-acid-base theory, which states that soft acids form stronger bonds with soft bases, whereas hard acids form stronger bonds with hard bases 43 . Bi 3+ is an intermediate Lewis acid, which tends to form a stronger bond with the intermediate Lewis base Clcompared to the soft bases Brand I -, in line with the Raman spectroscopy results. Therefore, more energy is needed to break Bi-Cl bonds and to further form metallic Bi. Furthermore, when the Bi-Cl bonds are finally broken and Bi monomers are formed, a sudden burst of nucleation and growth of metallic Bi occurs, evidenced by the short-lived transition state in the in situ XANES results, causing the preferred formation of edge planes (Bi(012) in this case over ordered basal planes, for example Bi(003)). The long-lived transition state indicates that BOB and BOI could be continuously reduced into metallic Bi, which is inferred to be beneficial for the formation of ordered basal plane structures with optimized catalytic performance for CO 2 conversion into formic acid 33 .

Conclusions
Layered {001}-oriented Bi oxyhalides (that is BiOX, with X = Cl, Br or I) electrocatalysts were synthesized and used as templates for in situ formation of Bi electrocatalysts in the selective CO 2 reduction reaction to formic acid. Using a GDE flow cell, the partial current density of formic acid in the prepared BiOBr (BOB) catalyst could reach up to 148 mA cm -2 with a near unity formic acid selectivity at −1.05 V versus RHE. Furthermore, formic acid selectivities of 76 and 69% were observed for BOI and BOC at −1.08 V versus RHE and −1.09 V versus RHE, at current densities of 95 and 88 mA cm -2 , respectively. Through in situ Raman spectroscopy and XRD, it was found that the pristine BiOX electrocatalysts are converted into metallic Bi, but that the formation of the active sites is heavily influenced by the halide: bromide promotes Bi(003), chloride results in preferred Bi(012) exposure and iodide has an equal contribution of Bi(003) and Bi(012). This result combined with the catalytic performance trends suggests a structure-sensitivity relationship, in which the Bi(003) facet is more selective and active towards formic acid formation relative to the Bi(012) surface. In situ XAS measurements showed that the reconstruction of BOC proceeds rapidly, but at a higher cathodic bias, as compared to BOB and BOI. This suggests that the reconstruction rate of BiOX could determine facet exposure during catalysis in the presence of halides. This work provides insights into the active site of in situ-activated Bi-based electrocatalysts in the eCO 2 RR through multiscale in situ characterization and potentially paves the way for the rational design of other electrocatalysts for renewable production of chemicals and fuels.

Catalyst preparation
The studied BiOX materials (with X = Br, Cl or I) were synthesized by hydrothermal synthesis, modified from previously reported work 57-59 . In the procedure to obtain BiOBr, 5 mmol Bi(NO 3 ) 3 ·5H 2 O (Sigma-Aldrich, reagent grade, 98.0%) and 5 mmol cetyltrimethylammonium bromide (Sigma-Aldrich, ≥98.0%) were dissolved in 100 ml ultrapure water at room temperature for 40 min with stirring, followed by the addition of 1 M NaOH (Sigma-Aldrich, reagent grade, ≥98.0%) solution to adjust the pH to 7. After 1 h stirring, 80% of the mixed solution was poured into a 100 ml Teflon-lined stainless steel autoclave. The autoclave was then heated to 170 °C for 17 h before being cooled to room temperature in 13

Characterization
The phase structure of the studied materials was determined by XRD measurements on a Bruker D8 Phaser diffractometer equipped with a Cu Kα source (λ = 1.54056 Å) for both ex situ and in situ measurements.
Grazing incidence X-ray diffraction (GIXRD) measurements were also conducted on the Bruker D8 Phaser diffractometer using a θ of 0.3°. The morphology was studied using a scanning electron microscope (Phenom ProX). AFM measurements were performed with a Bruker Multimode microscope instrument, using silicon NSC−16 SCANASYST− AIR (F = 0.4 N m −1 , fres = 70 kHz) in ScanAsyst mode. The local crystal structure, morphology and elemental distribution within the particles were determined by conducting HAADF-STEM and STEM-EDS measurements on an aberration-corrected Thermo Fisher Scientific Titan electron microscope operated at 300 kV and equipped with the ChemiSTEM system 60 .

Electrochemical measurements
An Ivium Compactstat.h10800 potentiostat was used for electrochemical performance measurements. In a gas-tight H-cell with two separated chambers, a standard three-electrode system was built with a proton exchange membrane (Nafion 117, Dupont The potential-dependent catalytic performance was probed using a potentiostatic (chronoamperometry) test at different cathodic potentials. Each potential was held for around 40 min.

Product analysis
Online gas chromatography, together with a thermal conductivity detector and a flame ionization detector, was used for analysis of gas products. For determination of liquid products, 1 H NMR spectro scopy was employed using water suppression mode. After catalysis, 0.5 ml of electrolyte was extracted and mixed with 0.1 ml of deuterated water (Sigma-Aldrich, ≤1 ppm) as the lock solvent. Dimethyl sulfoxide (0.05 µl) (Sigma-Aldrich, ACS reagent, ≥99.9%) was added as the internal reference.
The Faradaic efficiency (FE) of gas products was calculated using equation (2) The production rate of all products was calculated using equation (3) Production rate = where n represents the number of electrons involved to produce the related products from CO 2 or H 2 O (for example 2 for CO and H 2 and 12 for C 2 H 4 ), F is the Faraday constant (96,485 C mol −1 ), c is the concentration of the product measured by gas chromatography, f is the gas flow rate (ml min −1 ), I is the average measured current in 1 min (A), V m is the volume of 1 mol gas at the reaction temperature and pressure (24,451 ml mol −1 ) and S represents the geometric area of the electrode (cm 2 ). The FE of liquid products was calculated by using equation (4) where n is the number of electrons transferred to form the desired product (for example 2 for HCOOH), F is the Faraday constant (96,485 C mol −1 ), M is the molar concentration of the liquid product, V is the liquid volume, I is the average measured current in 1 min (A) and t is the duration time (s).

In situ Raman spectroscopy measurements
A Renishaw inVia Raman microscope and a 532 nm excitation laser coupled with a Nikon N40X - NIR water-dipping objective were used for the in situ Raman spectroscopy measurements. The laser power was set to below 1.5 mW in order to avoid laser damage. The time interval for each spectrum was 10 s for all measured samples. The in situ Raman spectroscopy measurements were coupled with chronoamperometry measurements, for which an Autolab PGSTAT 101 potentiostat was used with a scanning rate of 50 mV s −1 in CO 2 -saturated 0.1 M KHCO 3 electrolyte solution (pH 6.8), at a potential of −1.15 V versus RHE. The same in situ Raman cell as previously published by our group was used for these measurements (Supplementary Fig. 41) 9 .

In situ XRD measurements
A Bruker D8 Phaser diffractometer was employed for the in situ XRD measurements. In a custom-made in situ cell ( Supplementary Fig. 42), Article https://doi.org/10.1038/s41929-023-01008-0 a glassy carbon wafer (SIGRADUR K films, diameter 22 mm, thickness 180 µm) coated with catalyst, a Pt wafer and an Ag/AgCl electrode were used as the working electrode, counter electrode and reference electrode, respectively. A back-illumination configuration was used for the measurement under Bragg mode. The electrolyte (CO 2 -saturated 0.1 M KHCO 3 solution) was introduced into the cell with a flow rate of 10 ml min −1 . An Ivium Compactstat.h10800 potentiostat was used for the chronoamperometry tests in the time-and potential-dependent in situ XRD measurements.

In situ XANES measurements
The Bi L 3 -edge high-energy resolution fluorescence detection X-ray absorption near-edge spectroscopy (HERFD-XANES) measurements were performed at the high-brilliance beamline ID26 of the European Synchrotron Radiation Facility (ESRF) in Grenoble, France. The storage ring operated in uniform multi-bunch mode with an electron current of 200 mA. Three undulators (u35) generated the incoming radiation, which was monochromated using a cryogenically cooled Si(111) double crystal monochromator. The X-rays were focused by two bent Pd mirrors to a size of ~210 × 105 µm 2 (horizontal × vertical) at the sample position. The detector was a Si Avalanche Photo-Diode (APD) with 200 µm thickness and 10 × 10 mm 2 active area. The size of an X-ray focus spot on the sample surface was 1 µm × 1 µm. For each spectrum, the acquisition time was set to 2 min. The same home-made in situ cell that was used for in situ XRD measurements with back-illumination configuration was used again for the in situ XANES measurements. However, the cell was tilted 90° to meet the measurement condition (fluorescence mode, Supplementary Fig. 42). A glassy carbon wafer (SIGRADUR K films, diameter 22 mm, thickness 180 µm) coated with catalyst, a Pt wafer and an Ag/AgCl electrode were used as the working electrode, counter electrode and reference electrode, respectively. The electrolyte (CO 2 -saturated 0.1 M KHCO 3 solution) was introduced into the cell with a flow rate of 10 ml min −1 . An Ivium Compactstat.h10800 potentiostat was used for the chronoamperometry tests in the timeand potential-dependent in situ XAS measurements. Mass-flow controllers (Bronkhorst) controlled the gas atmosphere in the reactor. The preliminary data analysis and normalization were performed using the Data Analysis X-ray spectroscopy (DAXS) program available at the ESRF. The Athena software from the Demeter package was used for the LCF.

Data availability
The data that support the findings of this study are presented in the text and Supplementary Information. Source data are provided with this paper. Additional data and information are available from the corresponding authors upon request.