# First joint absorption and T_e-based metallicity measured in a GRB host galaxy at z = 4.28 using JWST/NIRSpec

Anne Inkenhaag, Patricia Schady, Phil Wiseman, Robert M. Yates, Maryam Arabsalmani, Lise Christensen, Valerio d'Elia, Massimiliano de Pasquale, Rubén García-Benito, Dieter H. Hartmann, et al.

<figure><img src="image_1.png" /></figure>

## ► To cite this version:

Anne Inkenhaag, Patricia Schady, Phil Wiseman, Robert M. Yates, Maryam Arabsalmani, et al. First joint absorption and T_e-based metallicity measured in a GRB host galaxy at z = 4.28 using JWST/NIRSpec. Monthly Notices of the Royal Astronomical Society, 2025, 541 (4), pp.3837-3850. 10.1093/mnras/staf1103. hal-05410347

HAL Id: hal-05410347

https://hal.science/hal-05410347v1

Submitted on 10 Dec 2025

HAL is a multi-disciplinary open access archive for the deposit and dissemination of scientific research documents, whether they are published or not. The documents may come from teaching and research institutions in France or abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d'enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.

<figure><img src="image_2.png" /></figure>
# First joint absorption and $T_e$-based metallicity measured in a GRB host galaxy at $z = 4.28$ using JWST/NIRSpec

Anne Inkenhaag<sup>1,★</sup> Patricia Schady<sup>1</sup> Phil Wiseman<sup>1,2</sup> Robert M. Yates<sup>1,3</sup> Maryam Arabsalmani<sup>4,5</sup>

Lise Christensen,<sup>6,7</sup> Valerio D'Elia,<sup>8</sup> Massimiliano De Pasquale,<sup>9</sup> Rubén García-Benito<sup>10</sup>

Dieter H. Hartmann,<sup>11</sup> Páll Jakobsson,<sup>12</sup> Tanmoy Laskar,<sup>13,14</sup> Andrew J. Levan,<sup>14,15</sup> Giovanna Pugliese<sup>16</sup>

Andrea Rossi<sup>17</sup>, Ruben Salvaterra,<sup>18</sup> Sandra Savaglio,<sup>17,19,20</sup> Boris Sbarufatti<sup>21</sup>

Rhaana L. C. Starling,<sup>22</sup> Nial Tanvir,<sup>22</sup> Berk Topçu,<sup>1</sup> Susanna D. Vergani<sup>23</sup> and Klaas Wiersema<sup>3</sup>

*Affiliations are listed at the end of the paper*

Accepted 2025 July 1. Received 2025 June 9; in original form 2025 April 16

## ABSTRACT

We present the first gamma-ray burst (GRB) host galaxy with a measured absorption line and electron temperature ($T_e$) based metallicity, using the temperature sensitive [O III] $\lambda$4363 auroral line detected in the JWST/NIRSpec spectrum of the host of GRB 050505 at redshift $z = 4.28$. We find that the metallicity of the cold interstellar gas, derived from the absorption lines in the GRB afterglow, of $12 + \log(O/H) \sim 7.7$ is in reasonable agreement with the temperature-based emission line metallicity in the warm gas of the GRB host galaxy, which has values of $12 + \log(O/H) = 7.80 \pm 0.19$ and $7.96 \pm 0.21$ for two common indicators. When using strong emission line diagnostics appropriate for high-$z$ galaxies and sensitive to ionization parameter, we find good agreement between the strong emission line metallicity and the other two methods. Our results imply that, for the host of GRB050505, mixing between the warm and the cold interstellar medium along the line of sight to the GRB is efficient, and that GRB afterglow absorption lines can be a reliable tracer of the metallicity of the galaxy. If confirmed with a large sample, this suggest that metallicities determined via GRB afterglow spectroscopy can be used to trace cosmic chemical evolution to the earliest cosmic epochs and in galaxies far too faint for emission line spectroscopy, even for JWST.

**Key words:** gamma-ray burst: general – gamma-ray burst: individual: GRB 050505 – galaxies: abundances – gamma-ray bursts.

## 1 INTRODUCTION

The cosmic history of chemical enrichment is a key aspect of galaxy and stellar evolution. Obtaining accurate gas-phase metallicity measurements is necessary to trace the process of nucleosynthesis and enrichment of the interstellar medium through stellar feedback, which fuels and enriches successive generations of stars on a variety of time-scales (see Péroux & Howk 2020 for a review on the baryon cycle).

With the launch of the JWST, it has now become possible to measure the metallicity of galaxies out to higher redshift than was previously possible, which have their rest-frame optical light shifted into the thermal infrared and therefore effectively inaccessible using ground-based telescopes. Even with the Hubble Space Telescope (HST), the important [O III] nebular line doublet becomes inaccessible at $z \gtrsim 2.4$, and infrared spectroscopy options on HST were far more limited than on JWST. Since its launch, spectroscopic observations of large numbers of galaxies at $z > 3$ have been taken with JWST, providing metallicity measurements out to $z > 8$ (e.g. Arellano-Córdova et al. 2022; Schaerer et al. 2022; Curti et al. 2023;

Heintz et al. 2023; Nakajima et al. 2023; Rhoads et al. 2023; Trump et al. 2023; Sanders et al. 2024; Scholte et al. 2025).

Two main methods exist for measuring the metallicity in galaxies, which each probe different components of the galaxy. One method entails using the absorption lines in the spectrum of a background quasi stellar object (QSO) or long gamma-ray burst (GRB) in the galaxy. For those sources where Ly $\alpha$ absorption is redshifted into view for ground-based, optical telescopes ($z \gtrsim 2$) we can use absorption from singly ionized metal species to measure the metallicity of the neutral gas, $Z_{\text{abs}}$. Due to their high hydrogen column densities, the clouds are self-shielded towards the high-ionization radiation, making the low-ionization metal absorption lines the dominant species, allowing us to measure accurate metallicities in absorption (e.g. Pettini et al. 1999; Prochaska et al. 2003a, 2007a, b; Prochaska, Castro & Djorgovski 2003b; Wolfe, Gawiser & Prochaska 2005; Savaglio 2006; Fynbo et al. 2010, 2011, 2013; Rafelski et al. 2012; Krogager et al. 2013; Neeleman et al. 2013; Cucchiara et al. 2015; Bolmer et al. 2019; Heintz et al. 2023). Because this method is not limited by the luminosity of the galaxy, it can measure metallicities even for galaxies too faint to be detected by HST and potentially even with JWST (Starling et al. 2005; Tanvir et al. 2012; Schulze et al. 2015). This is potentially critical in understanding enrichment in more ‘typical’ galaxies at high redshift, and metallicities out to $z > 6$ have been measured this way (e.g. Kawai et al. 2006; Thöne

<footnote>* E-mail: ai707@bath.ac.uk</footnote>
et al. 2013; Hartoog et al. 2015; Saccardi et al. 2023). Another, and the most common, method makes use of emission lines in the spectra of star-forming galaxies. These emission lines are predominantly produced by the ionized gas within the bright star-forming (SF) regions, and emission line metallicities, Z<sub>SF</sub>, are thus star formation rate weighted. This method is flux limited, as only the brightest sources will have emission lines with sufficiently high enough signal-to-noise (S/N) ratio to employ this method.

The most accurate method to measure the gas phase metallicities from emission lines is by using the temperature sensitive ($T_e$) auroral-to-nebular line ratios of the same ionic species, from which a reliable metallicity can be obtained, $Z_{SF}(T_e)$ (e.g. Peimbert 1967; Osterbrock 1989). However, these auroral lines are weak, the strongest one, [O III]$\lambda$4363 is still ~ $10^{-2}$ times fainter than H $\beta$. Alternative methods have thus been developed, which either use empirical or theoretical relations between various combinations of strong line (SL) ratios and $T_e$-based metallicities (see Maiolino & Mannucci 2019, for a detailed review).

Comparing metallicities obtained through strong line diagnostics shows that $Z_{SF}(\text{SL})$ and $Z_{\text{abs}}$ (either using QSO or GRB sightlines) of the same galaxy often do not agree, irrespective of the redshift range (compare e.g. De Cia et al. 2018 to Sanders et al. 2021 and Nakajima et al. 2023, although see Christensen, Hjorth & Gorosabel 2004; Friis et al. 2015; Rhodin et al. 2018 and Schady et al. 2024 for examples of finding (some) agreement between $Z_{\text{abs}}$ and $Z_{\text{SF}}(\text{SL})$). It is unclear whether the general disagreement has a physical origin, or if it is caused by selection effects in the galaxy sample (such as emission line spectroscopy being flux limited, and high S/N ratio absorption lines generally requiring dust-poor sightlines e.g. Schady et al. 2024), the strong line relations having unaccounted third parameter dependencies (e.g. Kewley & Dopita 2002), or $Z_{\text{SF}}(\text{SL})$ and $Z_{\text{abs}}$ not actually measuring the same component of the galaxy (e.g. Metha & Trenti 2020; Arabsalmani et al. 2023). The way to solve this issue would be to measure the $T_e$-based metallicity for the same galaxies with available $Z_{\text{abs}}$ metallicity measurements. Indeed, for QSO-based metallicities, the lines of sight passing through the galaxies are likely illuminating different gas than the SF gas responsible for emission line production. Using long GRBs has substantial advantages because the bursts themselves arise from the collapse of massive stars (e.g. Woosley 1993; Galama et al. 1998; Hjorth et al. 2003) and so should trace the same population of stars that are responsible for exciting emission lines. Whenever we mention GRBs in this paper, we specifically mean long GRBs that arise from the collapse of a massive star.

We present new observations of the host galaxy of GRB 050505 taken with JWST/NIRSpec, in which we detect [O III]$\lambda$4363 signifying the first detection of this weak line in a GRB host galaxy at $z > 0.1$. These data complete the cycle-1 GRB host sample (PI: Schady; ID 2344) first presented in Schady et al. (2024). An absorption line metallicity from the optical afterglow spectrum of GRB 050505 was reported in Berger et al. (2006) with a value of [M/H] $\approx -1.2^1$, corresponding to an oxygen abundance of $12 + \log(O/H) \approx 7.5$. This direct measurement of the emission line metallicity allows us, for the first time, to bridge the currently uncertain gap between the ionized and neutral ISM in a GRB host galaxy at high redshift (e.g. Metha & Trenti 2020; Arabsalmani et al. 2023). The host of GRB 050505 is the only host galaxy from our JWST cycle-1 proposal with detected [O III]$\lambda$4363 emission and thus Schady et al. (2024) only derive an upper limit of $T_e$([O III]) < 35000 K for $Z_{\text{SF}}(T_e)$ using the stacked spectra of the other sources.

$$ ^1[\text{X/Y}] = \frac{\log N(\text{X})}{\log N(\text{Y})} - \frac{\log N(\text{X})_\odot}{\log N(\text{Y})_\odot} $$

<figure><img src="image_3.png" /><figcaption>**Figure 1.** HST F110W-band image of the host galaxy of GRB 050505. The position of the NIRSpec fixed slit is indicated with the dashed rectangle and the + represents the GRB position. The image is oriented with north up and east to the left, and the scale of the image is given in the bottom left corner.</figcaption></figure>

In Section 2, we describe the observations of the host of GRB 050505 and the data reduction process. We present our analysis and results in Section 3 and discuss the implications of the results in context of the general GRB host population in Section 4. In this section, we also compare the metallicities obtained through different methods, discuss the validity and value of each and we estimate the stellar mass of the host galaxy which we place in the wider context of galaxy evolution. We draw our final conclusions in Section 5.

We assume a standard Lambda cold dark matter ($\Lambda$CDM) cosmological model with $H_0 = 67.8 \text{ km s}^{-1} \text{ Mpc}^{-1}$, $\Omega_m = 0.308$, and $\Omega_\Lambda = 0.692$ (Planck Collaboration XIII 2016). Uncertainties are $1\sigma$ unless specified otherwise and upper limits are at the $3\sigma$ confidence level.

## 2 DATA

### 2.1 Observations and data reduction

The host of GRB 050505 was observed on 2024 March 29 with the JWST/NIRSpec S400A1 fixed slit (0.4 slit width), using a two-point nod pattern. We used two grating and filter combinations (G235M/F170LP and G395M/290LP) with on source exposure times of 2042s and 584s, respectively, to cover the rest-frame wavelength range between [O II]$\lambda$3726,3729 and H $\alpha$ at the redshift of the galaxy previously determined from the GRB afterglow spectrum ($z = 4.275$; Berger et al. 2006). The resolving power of the NIRSpec gratings that we used is $R = 700-1400$, corresponding to a line width velocity dispersion of $\sigma = 90-200 \text{ km s}^{-1}$ for both grating/filter combinations. The observations were part of a larger cycle 1 JWST campaign, and the rest of the sample, which were observed prior to the data presented here, are analysed and discussed in Schady et al. (2024). In Fig. 1, we show an HST/F110W image (program ID 15644) centred on the host galaxy of GRB 050505 with the position of the NIRSpec fixed slit indicated with the two dashed lines. The
<figure><img src="image_4.png" /><figcaption>**Figure 2.** Spectrum of the host of GRB 050505, zoomed in on the wavelength region where emission lines were detected. The blue line (3500–6000 Å) is the spectrum taken using the G235M/F170LP grism/filter combination and the orange line (5400–7000 Å) is the spectrum taken using the G395M/F290LP grism/filter combination. The spectrum has been de-redshifted to the rest frame wavelengths to allow for easier emission line identification and the emission lines listed in Table 1 are labeled using vertical dashes.</figcaption></figure>

GRB position is represented by the + sign, and is accurate to within two image pixels, or ~ 1 kpc in physical units.

The reduced and calibrated 2D spectra were downloaded from the Mikulski Archive for Space Telescopes (MAST) Data Discovery Portal.<fnref n="2" /> The data were reduced with version 11.17.14 of the CRDS file selection software, using context jwst_1236.pmap, and were calibrated with version 1.13.3 of the calibration software. We extract the 1D spectrum from the 2D spectrum using the Extract1DStep() function from the PYTHON JWST pipeline (v1.14.1 Bushouse et al. 2025). We show the rest-frame spectrum of the host of GRB 050505 in Fig. 2, zoomed into the wavelength range where emission lines are detected.

# 3 ANALYSIS AND RESULTS

## 3.1 Line fluxes

In the spectrum, we detect the following lines: [O II]λλ3726,3729, [Ne III]λλ3869, 3967, He Iλ3889, H γ, [O III]λ4363, H β, [O III]λλ4959,5007, H α and [S II]λλ6717, 6731. We do not detect significant emission at the position of [N II]λλ6548, 6584 but we do detect a faint galaxy continuum in the bluer of the two spectra (1.7 – 3.1 μm observer frame).

To obtain the emission line fluxes, we fit a single Gaussian to each emission line using the PYTHON package LMFIT. To take into account potential imperfect background subtraction and the faint galaxy continuum, we also fit a first-order polynomial to create a baseline for the Gaussian fits. For greater constraint we first fit H β and the [O III]λλ4959,5007 doublet simultaneously, which are the lines with the highest S/N in the spectrum, and the combined fit provides additional constraint to the best-fitting parameters (see Fig. 2). We fit four independent parameters in this fit: the redshift of the galaxy z, the velocity line width σ, and two line amplitudes (H β and [O III] λ5007). The peak wavelengths are tied to the theoretical wavelength separation, redshifted to the observer frame. We also keep the velocity line-width (σ) tied between the lines, taking into account the NIRSpec line spread function (we assume all emission lines come from the same gas, the integrated light from the SF regions), and we fix the ratios of the amplitudes of the [O III]λλ4959,5007 doublet to the theoretical value of [O III] λ5007/λ4959 = 2.98 (Storey &

Zeippen 2000). The fits of all other lines were then fixed to the best-fitting values of σ = 89 ± 3 km s⁻¹ and z = 4.27788 ± 0.00003, from the H β and [O III]λλ4959,5007 fit. The uncertainty on the redshift includes the NIRSpec wavelength calibration uncertainty, which is ~ 0.8 Å.<fnref n="3" /> We find no strong evidence for observable differences in the Doppler shifts of the lines from different ionic species at the resolution of NIRSpec.

The [O II]λλ3726,3729 doublet is blended due to the resolution of NIRSpec (~ 23.5 Å in the G235M/F170LP grating/filter combination), which is greater than the separation of the doublet at the observed wavelength (~ 14 Å at z = 4.28). However, using the constraints on the redshift and the velocity width, we can fit two Gaussians to this doublet. Emission from the [Ne III]λ3967 line in the [Ne III] doublet and the [He I]λ3889 line can also be blended with higher order Balmer lines (i.e. Hε and H8). We therefore tried fitting each of these lines with two Gaussians corresponding to the rest-frame peak wavelength of [He I]λ3889 + H8 and [Ne III]λ3967 + Hε. However, no significant emission was detected at the position of Hε or H8, and we therefore use the [Ne III] and [He I] best-fitting line fluxes from our single Gaussian fits to each line. For the [S II]λλ6717,6731 doublet we detect only one line above the background noise, consistent with emission from [S II]λ6717. We therefore force the amplitude ratio between these two lines in the doublet to the maximum value of [S II]λ6717/λ6731 = 1.4 (Osterbrock & Ferland 2006), resulting in a fit with reduced χ<fnref n="2" /> = 1.3 (see the bottom right panel in Fig. A1). This amplitude ratio is valid for low-density environments (n_e ≲ 100 cm⁻<fnref n="3" />), which are common for H II regions also in GRB hosts (e.g. Piranomonte et al. 2015; Izzo et al. 2017). This constraint changes the flux of [S II]λ6717 from 0.30 ± 0.06 erg s⁻¹ cm⁻<fnref n="2" />, when fitting just a single Gaussian to this line, to 0.20 ± 0.06 erg s⁻¹ cm⁻<fnref n="2" />, when fitting both lines in the doublet while forcing the above amplitude ratio. For the [N II]λλ6549,6584 doublet we determine 3σ upper limits on the line fluxes by forcing Gaussian fits at the expected observer-frame wavelengths, setting the line ratio to the theoretical value and fixing σ to our previous, best-fitting value. The [O III]λ4363 auroral line is a weak line (see Fig. 3), as are the [S II]λλ6717,6731 lines and the [N II]λλ6549,6584 upper limit, so constraining its peak position and line width therefore improves the reliability of the flux we measure.

As a check, we also perform the fits leaving σ as a free parameter between the fits but tying it for all sets of lines fit simultaneously.

<footnote n="2">²https://mast.stsci.edu/portal/Mashup/Clients/Mast/Portal.html</footnote>

<footnote n="3">³https://jwst-docs.stsci.edu/jwst-calibration-status/nirspec-calibration-status/nirspec-fixed-slit-calibration-status</footnote>
<figure><img src="image_5.png" /><figcaption>**Figure 3.** Fit of the H γ and [O III]λ4363 emission lines of the host of GRB 050505. The data are shown in individual, blue data points and the combined Gaussians that were fit to the data are plotted as a black solid line. The shaded area corresponds to the 3σ error of the best combined fit to the data. The central wavelengths and line widths or all lines were fixed to the values obtained from the fit of H β and [O III]λλ4959,5007 (see Fig. A1, panel 3) as these lines have the highest SNR. The centroid of both lines are marked with vertical dashes. The bottom panel shows the residuals of the data after subtracting the best fit.</figcaption></figure>

Doing this does not influence the final results significantly, so we opt for leaving it tied to the best fit from H β and [O III]λλ4959,5007 for consistency. We also investigate the influence of not fixing the redshift between fits, but leaving Δz between the lines to the theoretical value. While we expect all lines to have the same, best-fitting redshift, we want to investigate how much spread there would be if the redshift were left as a free parameter and how this influences the final results. Leaving z as a free parameter for all lines (but keeping σ fixed) most significantly influences the fit of the Hγ and [O III]λ4363 line, with the H γ line fitting at higher redshift and the [O III]λ4363 line fitting at lower redshift than the best-fitting value from the H β and [O III]λλ4959,5007 fit. The flux of the [O III]λ4363 auroral line is increased by ~5 per cent, resulting in a higher electron temperature and therefore a lower metallicity by 0.02 dex, which is still well within the uncertainty. Leaving z free in the fit results in a fit with reduced χ² = 1.4 compared to reduced χ² = 2.1 when fixing z. However, since the [O III]λ4363 line comes from the same atomic species as the [O III]λ5007 line, we expect it to be at the same redshift, and we therefore leave the redshift fixed to the value obtained from the [O III]λλ4959,5007 and H β fit.

We correct the line flux for extinction using the PYTHON package DUST_EXTINCTION (v1.4.1; Gordon 2024). We first correct the emission line fluxes for Milky Way (MW) extinction at the observed wavelength using the G23 model (Gordon et al. 2023) and setting the total-to-relative dust reddening value to R_V = 3.08 (Cardelli, Clayton & Mathis 1989). This dust reddening model has the advantage that it covers the whole NIRSpec wavelength range and is based on the spectroscopic extinction curves from Gordon, Cartledge & Clayton (2009), Fitzpatrick et al. (2019), Gordon et al. (2021), and Decleir et al. (2022). It is therefore recommended by the developers when correcting for MW-type extinction. We use a Galactic reddening value of E(B-V) = 0.019 obtained using the PYTHON package GDPYC along the GRB host galaxy line of sight, with the Schlegel, Finkbeiner & Davis (1998) dust map and corrected for the Schlafly & Finkbeiner (2011) recalibration of this dust map.

<table><caption>**Table 1.** Results of line fitting of the emission lines of the host of GRB 050505 (both non-corrected and corrected for Milky Way and host galaxy dust) used in this work to calculate strong line ratios using z = 4.27787 ± 0.00003 obtained from the [O III]λλ4959,5007 and H β fit (see the main text for details). Plots of the line fits can be found in Figs 3 and A1 in the appendix.</caption><thead><tr><th>Emission line</th><th>Uncorrected flux<br>(10<sup>-17</sup> erg s<sup>-1</sup> cm<sup>-2</sup>)</th><th>Corrected flux<br>(10<sup>-17</sup> erg s<sup>-1</sup> cm<sup>-2</sup>)</th></tr></thead><tbody><tr><td>[O II]λ3727</td><td>0.36±0.04</td><td>0.77±0.24</td></tr><tr><td>[O II]λ3730</td><td>0.49±0.04</td><td>1.06±0.32</td></tr><tr><td>[Ne III]λ3869</td><td>0.22±0.03</td><td>0.47±0.14</td></tr><tr><td>[He I]λ3889</td><td>0.11±0.03</td><td>0.23±0.09</td></tr><tr><td>[Ne III]λ3967</td><td>0.08±0.03</td><td>0.16±0.07</td></tr><tr><td>H δ</td><td>0.13±0.04</td><td>0.28±0.11</td></tr><tr><td>H γ</td><td>0.24±0.03</td><td>0.49±0.14</td></tr><tr><td>[O III]λ4364</td><td>0.08±0.03</td><td>0.15±0.07</td></tr><tr><td>H β</td><td>0.59±0.03</td><td>1.09±0.20</td></tr><tr><td>[O III]λ4960</td><td>1.23±0.02</td><td>2.26±0.50</td></tr><tr><td>[O III]λ5008</td><td>3.68±0.08</td><td>6.68±1.47</td></tr><tr><td>H α</td><td>2.02±0.09</td><td>3.12±0.58</td></tr><tr><td>[N II]λ6550</td><td>&lt;0.10</td><td>&lt;0.15</td></tr><tr><td>[N II]λ6585</td><td>&lt;0.29</td><td>&lt;0.45</td></tr><tr><td>[S II]λ6718</td><td>0.20±0.06</td><td>0.31±0.11</td></tr><tr><td>[S II]λ6733</td><td>0.14±0.04</td><td>0.22±0.08</td></tr></tbody></table>

We find corrections for MW extinction of the order of <1 per cent for all detected emission lines.

We then correct for the extinction in the host (at the rest fame wavelength of the emission lines) using a Small Magellanic Cloud (SMC) model. GRB host galaxies are generally low mass and metal poor and are thus more comparable to the SMC than e.g. the MW or the Large Magellanic Clouds (LMC; e.g. Schady et al. 2007). The G24_MCAvg model covers the wavelength range between 0.1 – 3.3 1 µm. We use E(B-V) = 0.18 ± 0.07 derived from the ratio between H α and H β and assuming a case-B Balmer decrement of 2.86 (Osterbrock 1989), which is appropriate for SF regions with temperature ~ 10⁴ K and electron densities n_e = 10² – 10⁴ cm⁻³. We find our electron temperature to be roughly consistent with this assumption (see Section 3), and while we cannot fit the electron density due to forcing the [S II]λλ6717,6731 doublet ratio to its maximum value, this ratio is valid for the lower end of the range in n_e values above. The Balmer decrement given from the uncorrected fluxes for both H γ and H δ with respect to H β result in E(B-V) estimates 0.26 ± 0.28 and 0.01 ± 0.5, which are consistent with the value we get when using the H α/H β Balmer decrement. The errors are significantly larger due to the large uncertainties in the H γ and H δ fluxes. The MW and host galaxy dust-corrected line fluxes are listed in Table 1, as well as the uncorrected for both MW and host galaxy extinction line fluxes.

## 3.2 Metallicities

### 3.2.1 T<sub>e</sub>-based diagnostics

The measured line fluxes in galaxy spectra predominantly depend on the gas-phase abundances and temperature (Peimbert 1967). Therefore, if we can measure the temperature of the gas, we can measure an accurate metallicity. More metal-poor gas is generally hotter, while metal-rich gas is generally cooler. As the [O III]λ4363 auroral line is extremely sensitive to temperature, hotter gas results in a brighter [O III]λ4363 line. The nebular [O III]λλ4959,5007 lines are less sensitive to temperature and will therefore be influenced less
<table><caption>**Table 2.** Electron temperatures and oxygen abundances for the host of GRB 050505, using the Izotov et al. (2006) and Yates et al. (2020) methods (see main text). Upper limits on the log(N/O) ratio are also estimated using four analytical prescriptions from the literature.</caption><thead><tr><th>Parameter</th><th>I06</th><th>Y20</th></tr></thead><tbody><tr><td>T<sub>e</sub>([O III])</td><td>16000 ± 3000 K</td><td>16000 ± 4000 K</td></tr><tr><td>T<sub>e</sub>([O II])</td><td>14400 ± 1200 K</td><td>10000 ± 3000 K</td></tr><tr><td>12 + log(O<sup>++</sup>/H<sup>+</sup>)</td><td>7.69 ± 0.20</td><td>7.72 ± 0.25</td></tr><tr><td>12 + log(O<sup>+</sup>/H<sup>+</sup>)</td><td>7.18 ± 0.16</td><td>7.59 ± 0.44</td></tr><tr><td>12 + log(O/H)</td><td>7.80 ± 0.19</td><td>7.96 ± 0.21</td></tr><tr><td>log(N/O)</td><td colspan="2">&lt; -0.77<sup>(a)</sup><br>&lt; -0.66<sup>(b)</sup><br>&lt; -0.90<sup>(c)</sup><br>&lt; -0.97<sup>(d)</sup></td></tr></tbody></table>

Note. References: (a) Thurston, Edmunds & Henry (1996), (b) Izotov et al. (2006), (c) Pilyugin, Vílchez & Thuan (2010), (d) Pilyugin & Grebel (2016).

by changes in temperature of the gas. The ratio between the nebular [O III]λ5007 and the auroral [O III]λ4363 line is therefore smaller in hotter (or more metal-poor) gas.

To calculate the electron temperature, we assume a two-zone ionization model, in which the inner region is hotter and is traced by [O III] emission and the outer region is colder and thus traced by [O II] emission. Ideally, we would want to detect the [O II]λλ7320,7330 and [O III]λ4363 auroral lines in order to measure $T_e([O II])$ and $T_e([O III])$ directly. These two temperatures can then be used to calculate $12 + \log O^+/H^+$ and $12 + \log O^{++}/H^+$, which combined give the average $T_e$-based metallicity, $Z_{SF}(T_e)=12 + \log(O/H) = 12 + \log(O^+/H^+ + O^{++}/H^+)$ (we assume the contribution of $O^{++}$ and higher ionization states is negligible, e.g. Izotov et al. 2006; Stasińska et al. 2012). In the case where the [O II]λλ7320,7330 auroral lines are not detected (as in this work), we have to assume a relation between $T_e([O II])$ and $T_e([O III])$ to obtain $T_e([O II])$.

Based on the nebular lines and the [O III] auroral line listed in Table 1, we calculate $T_e([O III])$ and hence $T_e([O II])$ using two different methods which roughly bracket the range of values obtained from the broad literature on $T_e([O III])–T_e([O II])$ relations (see e.g. Yates et al. 2020). The first method is from Izotov et al. (2006), using their equations (1) and (2) to calculate $T_e([O III])=16000 ± 3000$ K and then equation (14) for intermediate-metallicity systems to infer $T_e([O II])=14400 ± 1200$ K, resulting in $12 + \log(O/H) = 7.80 ± 0.14$. Their $T_e([O III])–T_e([O II])$ relation is a second-order polynomial fit to data from the photoionization models of Stasińska & Izotov (2003). The second method is from Yates et al. (2020), using their equation (3); taken from Nicholls et al. (2013) to calculate $T_e([O III])=16000 ± 4000$ and then equations (9) and (10) to iteratively obtain both $T_e([O II])=10000 ± 3000$ K and $12 + \log(O/H) = 7.96 ± 0.21$. Their $T_e([O III])–T_e([O II])$ relation is calibrated on an observational data set containing both individual H II region spectra and whole-galaxy spectra, and has the additional flexibility of allowing a range of $T_e([O II])$ values at fixed $T_e([O III])$ by incorporating metallicity into the fit. Equations (2) and (5) from Nicholls et al. (2014) were then used in both cases to calculate $Z_{SF}(T_e)$ from the electron temperatures. The values obtained from these two methods are shown in Table 2. The Yates et al. (2020) method returns an $T_e([O II])$ estimate of 10 260 K (which is ~ 4000 K lower than the Izotov et al. 2006 method) and hence a higher overall $T_e$-based metallicity of 7.96 (by ~ 0.16 dex). This difference is within the scatter in SDSS data around the Izotov et al. (2006) relation at high $T_e([O III])$ (see their fig. 4a).

### 3.2.2 Strong line diagnostics

As in Schady et al. (2024) we use the $\hat{R}$ diagnostics from Laseter et al. (2024; LMC24 from now on), and the metallicity diagnostics calibrated by Nakajima et al. (2022; NOX22 from now on), and Sanders et al. (2024; SST24 from now on) to calculate the strong line emission metallicity. Additionally, we also use Strom et al. (2018; S18 from now on) and the recently published recalibrated $\hat{R}$ diagnostic from Scholte et al. (2025; SCC25 from now on). The diagnostics that we consider are suitable for use at higher redshift because they were calibrated to conditions of high-z galaxies. They make use of the following strong line ratios:

$$ 
\begin{aligned}
R_{23} &= \frac{[O \text{ III}]\lambda\lambda3726, 3729 + [O \text{ III}]\lambda\lambda4959, 5007}{H \beta} \\
R_{3} &= \frac{[O \text{ III}]\lambda5007}{H \beta} \\
R_{2} &= \frac{[O \text{ III}]\lambda\lambda3726, 3729}{H \beta} \\
O_{32} &= \frac{[O \text{ III}]\lambda5007}{[O \text{ III}]\lambda\lambda3726, 3729} \\
Ne_{3}O_{2} &= \frac{[O \text{ III}]\lambda\lambda3726, 3729}{[S \text{ II}]\lambda\lambda6717, 6731} \\
S_{2} &= \frac{H \alpha}{[N \text{ II}]\lambda6584} \\
N_{2} &= \frac{H \alpha}{[N \text{ II}]\lambda6584/H \beta} \\
O_{3}N_{2} &= \frac{[O \text{ III}]\lambda5007/H \beta}{[N \text{ II}]\lambda6584/H \alpha} \\
\hat{R} &= 0.47 \times \log R_{2} + 0.88 \times \log R_{3}
\end{aligned}
$$

We use the fluxes listed in Table 1 to calculate the various SL ratios considered in this paper and then convert these to a metallicity for each calibration sample mentioned above. The plots in Appendix B show the relations between line ratio and $T_e$-based metallicity for each of the diagnostics that we consider, and our measured galaxy line ratios and corresponding uncertainty are plotted as horizontal shaded regions. The metallicities that we measure for each diagnostic are listed in Table 3. In those cases where the measured line ratio lies $1\sigma$ above (below) the valid range provided by each of the diagnostics, we report the metallicity corresponding to the maximum (minimum) allowed line ratio without giving errors.

For the SST24 calibrations we limit ourselves to the metallicity range where the fits to their data have an uncertainty in (O/H) better than 0.1 dex, $7.4 < 12 + \log(O/H) < 8.3$. We do not detect the continuum emission of the galaxy in the spectrum, so we are unable to determine the equivalent width (EW) of the emission lines, and we can therefore not use the EW(H β)-dependent diagnostics from NOX22. NOX22 argue that EW(H β) can be used as a tracer of the ionization state of the galaxy ISM, with low-EW(H β) corresponding to low ionization and high-EW(H β) corresponding to high ionization. In the early universe, ionization was higher (e.g. Kewley et al. 2013a, b; Steidel et al. 2014; Strom et al. 2018), and thus NOX22 argue that the high-EW(H β) calibrations are more appropriate for high-z galaxies. Using a sample of 10 galaxies at $z = 4 - 8.5$, Nakajima et al. (2023) confirmed that the high-EW(H β) calibrations are indeed more accurate for high-z galaxies, irrespective of the actual EW(H β) value. The ionization ratio in the host of GRB 050505 is also high ($\log([O \text{ III}]\lambda5007/[O \text{ III}]\lambda\lambda3726,3729) \sim 0.6$, similar to e.g. the high excitation sample from Stasińska et al. 2015) and we therefore use the high-EW(H β) calibrations for the host of
<table><caption>**Table 3.** Metallicities values obtained using various strong line relations. The associated plots can be found in Fig. B1.</caption><thead><tr><th>Diagnostic</th><th>Line ratio value</th><th>12 + log(O/H)</th></tr></thead><tbody><tr><td><strong>NOX22</strong></td><td></td><td></td></tr><tr><td>R<sub>23</sub><sup>a</sup></td><td>9.6 ± 0.5</td><td>7.90 ± 0.12</td></tr><tr><td>R<sub>3</sub><sup>a</sup></td><td>6.12 ± 0.32</td><td>7.75 ± 0.08</td></tr><tr><td>R<sub>2</sub></td><td>1.68 ± 0.21</td><td>8.17 ± 0.06</td></tr><tr><td>O<sub>32</sub></td><td>3.63 ± 0.35</td><td>7.07 ± 0.04, 8.05 ± 0.04</td></tr><tr><td>Ne<sub>3</sub>O<sub>2</sub></td><td>0.25 ± 0.04</td><td>7.54<sup>b</sup></td></tr><tr><td>S<sub>2</sub></td><td>0.17 ± 0.04</td><td>8.34 ± 0.07</td></tr><tr><td>N<sub>2</sub></td><td>&lt; 0.15</td><td>&lt; 8.48</td></tr><tr><td>O<sub>3</sub>N<sub>2</sub></td><td>&gt; 42</td><td>&lt; 8.34</td></tr><tr><td><strong>SST24</strong></td><td></td><td></td></tr><tr><td>R<sub>23</sub></td><td>9.6 ± 0.5</td><td>7.72 ± 0.13</td></tr><tr><td>R<sub>3</sub></td><td>6.12 ± 0.32</td><td>7.59 ± 0.08, 8.26 ± 0.08</td></tr><tr><td>R<sub>2</sub></td><td>1.68 ± 0.21</td><td>8.15 ± 0.05</td></tr><tr><td>O<sub>32</sub></td><td>3.63 ± 0.35</td><td>8.14 ± 0.04</td></tr><tr><td>Ne<sub>3</sub>O<sub>2</sub></td><td>0.25 ± 0.04</td><td>8.21 ± 0.07</td></tr><tr><td><strong>S18</strong></td><td></td><td></td></tr><tr><td>R<sub>23</sub></td><td>9.6 ± 0.5</td><td>8.24 ± 0.13<sup>c</sup></td></tr><tr><td>O<sub>3</sub>N<sub>2</sub></td><td>&gt; 42</td><td>&lt; 8.41</td></tr><tr><td>N<sub>2</sub></td><td>&lt; 0.15</td><td>&lt; 8.49</td></tr><tr><td><strong>LMC24</strong></td><td></td><td></td></tr><tr><td>R&#773;</td><td>0.80 ± 0.04</td><td>8.12<sup>b</sup></td></tr><tr><td><strong>SCC25</strong></td><td></td><td></td></tr><tr><td>R&#773;</td><td>0.80 ± 0.04</td><td>8.17<sup>b</sup></td></tr></tbody></table>

Notes. <sup>a</sup>For these diagnostics we found a solution with 12 + log (O/H) < 8 using the high-EW calibration in NOX22, so we present those results. For the other NOX22 lines we used the average-EW calibration.

<sup>b</sup>For these values the line ratio in question is smaller (bigger) than the minimum (maximum) value covered by the diagnostic (Ne<sub>3</sub>O<sub>2</sub>-NOX22 < -0.41, R&#773;<sub>LMC24</sub> > 0.76 and R&#773;<sub>SCC25</sub> > 0.75 at 1σ). We therefore present the turnover point between the upper and lower branch as the resulting best-fitting metallicity (see Fig. B1).

<sup>c</sup>In these cases the measured line ratios are larger than the maximum value, but still within 1σ of the maximum values (see Fig. B1). We therefore assign the metallicity associated with the maximum line ratio, but also include and error.

GRB 050505 despite not being able to measure EW(H β). The high-EW calibrations are only valid for 12 + log(O/H) ≤ 8, and thus for those NOX22 diagnostics where we measure 12 + log(O/H) > 8, we then re-calculate the metallicity using the EW-averaged diagnostics.

For diagnostics that use the [N II]λ6584 line, which are the N<sub>2</sub> and the O<sub>3</sub>N<sub>2</sub> diagnostics, the metallicities listed are upper limits as we only have an upper limit for this emission line (see Table 1 and Fig. A1). The N<sub>2</sub> diagnostic is linear between 12 + log(O/H)~ 7.8 – 8.7 and although it is very sensitive to ionization parameter (e.g. Kewley & Dopita 2002), it can still be used to discriminate between double-branched solutions. The same argument holds for the O<sub>3</sub>N<sub>2</sub> diagnostic. For the SST24 calibration, we were unable to discriminate between the two solutions for R<sub>3</sub> (see Fig. B1), and in Table 3 we therefore give both the lower and the upper branch metallicities.

To determine the error on the metallicity calculations we perform Markov chain Monte Carlo in which we randomly draw values from the observed line ratios assuming a normal distribution with standard deviation equal to our measured line ratio standard deviations and compute the metallicity using the drawn line ratio. This is repeated 5000 times after which we use the median and the standard deviation for the distribution in metallicities to determine the most likely metallicity and 1σ uncertainty given the measured line ratios and

uncertainties. If the diagnostic is double branched we repeat this for both branches and report both values in Table 3.

Only NOX22 lists uncertainties on their diagnostics in the metallicity direction for all line ratios used in their table 4, which vary between 0.09 dex for R23 (high-EW) and 0.60 dex for Ne3O2 (average for all EWs). We only use the SST24 diagnostics in the range of metallicities for which they state the median 12 + log(O/H) uncertainty is <0.1 dex, so we use 0.1 dex as the systematic error on the SST24 calibrations. For the remaining calibration samples no uncertainties were given, and hence we adopt a systematic uncertainty of 0.2 dex for each diagnostic, which seems reasonable based on the systematic uncertainties from NOX22 and SST24. These systematic errors represent the scatter in the calibration sample about the best-fitting diagnostic. We add the systematic uncertainty of the calibration in quadrature to obtain the full uncertainty on the metallicity. In the cases where we present the metallicity without error in Table 3, we only use the systematic error on the calibration to compute the full uncertainty of the metallicity.

# 4 DISCUSSION

## 4.1 Host of GRB 050505 in the general GRB host galaxy sample

### 4.1.1 Electron temperatures

We compare the electron temperature of the host of GRB 050505 to that of other GRB host galaxies, GRB980425 ($T_e$([O III]) = 10 500 ± 0.0500 K at $z$ = 0.0086; Krühler et al. 2017), GRB031203 ($T_e$([O III]) = 13 400 ± 0.2000 K, $z$ = 0.1055; Prochaska et al. 2004), GRB060218 ($T_e$([O III]) = 24800<sup>+5000</sup><sub>-3000</sub> K, $z$ = 0.03342; Wiersema et al. 2007) and GRB100316 ($T_e$([O III]) = 11900 ± 800 K and $T_e$([O II]) = 10400 ± 1100 K, $z$ = 0.0591; Starling et al. 2011). While the value we measure for both $T_e$([O III]) as well as $T_e$([O II]) is higher than this small sample of GRB hosts, it is still generally consistent within 1σ. Nevertheless, the host galaxy of GRB 050505 is at significantly higher redshift than our small comparison sample ($z$ < 0.11), and $T_e$ is generally observed to be lower in the local SF galaxy population (see e.g. Shi et al. 2014; Hirschauer et al. 2015; Yates et al. 2020) than the high-$z$ SF population (see e.g. Schaerer et al. 2022; Rhoads et al. 2023). This is due to galaxies at lower redshift having higher metallicities because of galactic chemical enrichment over time. The $T_e$ values of the four local GRB hosts mentioned above are consistent with local SF galaxy samples (typically 7000–15 000 K; e.g. Shi et al. 2014; Hirschauer et al. 2015; Yates et al. 2020; Rogers et al. 2022, with the occasional exception of higher temperatures around 23 000 K such as observed in Hirschauer et al. 2015 and for GRB 060218 above). The host of GRB 050505, on the other hand, agrees better with the higher temperatures typically observed in high-$z$ SF galaxies (>15 000 K; e.g. Christensen et al. 2012; Patrício et al. 2018; Schaerer et al. 2022; Rhoads et al. 2023; Laseter et al. 2024; Sanders et al. 2024), although that sample is still small (of the order of tens of galaxies).

### 4.1.2 Galaxy characteristic properties

While the distribution of GRB host galaxy metallicities at $z \lesssim 3$ is offset towards lower metallicities when compared to the general population of SF galaxies at comparable redshifts, (e.g. Graham & Fruchter 2013, 2017; Krühler et al. 2015; Arabsalmani et al. 2018; Palmerio et al. 2019), GRB hosts do appear to follow the general trend in the mass-metallicity relation of SF galaxies (e.g. Vergani
et al. 2015; Arabsalmani et al. 2018, although see Graham, Schady & Fruchter 2023).

There is only a single HST WFC3/F110W observation of the host galaxy of GRB 050505. Photometry of this host galaxy in a 0.4 arcsec aperture provides an AB magnitude $F110W = 25.90 \pm 0.06$. This corresponds to an absolute magnitude of $M_{2000\AA} = -20.3$ and a UV indicated star formation rate of $\sim 1.5 M_{\odot} \text{ yr}^{-1}$ (using the normalization of Hirashita, Buat & Inoue 2003)). we note that the host galaxy is relatively luminous compared to other GRB hosts at $z > 4$ (Tanvir et al. 2012; Schulze et al. 2015; McGuire et al. 2016).

In order to measure the galaxy stellar mass, $M_*$, from the galaxy spectral energy distribution (SED), we first convolve the G235M/F170LP NIRSpec spectrum with the NIRCam F200W and F277W response curves. This results in measured AB magnitudes of $F200W = 25.36 \pm 0.20$ and $F277W = 24.66 \pm 0.15$ mags, which we combine with the HST/WFC3 F110W photometry to produce a UV/optical SED. After correcting for the Galactic foreground extinction, we modelled the SED using the code CIGALE<fnref n="4" /> (Boquien et al. 2019) with a redshift fixed to $z = 4.27$. Although the SED is too sparsely sampled to fully resolve the degeneracy between attenuation, age, and SFR, the JWST-estimated magnitudes above the Balmer break allow us to constrain the stellar mass to $\log(M_*/M_{\odot}) = 9.4 \pm 0.4$.

Using the dust corrected H α flux we calculate the star formation rate (Kennicutt 1998) of the host of GRB 050505, assuming the Chabrier (2003) initial mass function. We find a star formation rate (SFR) of $26 \pm 5 M_{\odot} \text{ yr}^{-1}$, which is consistent with the distribution of SFRs measured in larger samples of GRB host galaxies (e.g. Christensen et al. 2004; Krühler et al. 2015; Palmerio et al. 2019; Schneider et al. 2022). Combined with the stellar mass we find, the SFR suggests that the host of GRB 050505 lies on the main sequence for SF galaxies (e.g. Popesso et al. 2023; Curti et al. 2024). The combination of SFR and $T_e$-based we measure are also consistent with the fundamental metallicity relation from Sanders et al. (2020). We therefore conclude that our GRB host galaxy is consistent with the general population of SF galaxies.

The sample of $\sim 100$ GRB host galaxies from Perley et al. (2016) shows a wide range of stellar masses (see their fig. 3), but the sensitivity of their Spitzer observations did not allow them to probe galaxies at $z \gtrsim 4$ with stellar masses much smaller than $< 10^{10} M_{\odot}$. Similarly, there are not many GRB hosts with metallicities measured as low as $12 + \log(O/H) \sim 7.8$ for $Z_{SF}(T_e)$. This is likely due to selection effects because emission line spectroscopy is only available for the brightest sources (which tend to be more massive) and the [O III]\lambda4363 auroral line is weak, needing bright sources and longer integration times. It is only because of our sensitive JWST spectra that we are able to measure oxygen abundances down to far lower metallicities than previously possibly for other GRB hosts at comparable redshift.

## 4.2 Metallicity relations

The collapsar model (Woosley 1993) for long GRBs predicted an association between long GRBs and massive stars, and observations confirmed this (e.g. Galama et al. 1998; Hjorth et al. 2003). This means their sightline emanates from the same SF regions that dominate the emission line spectra. We can use the absorption imprint left on the afterglow spectra of these long GRBs to probe the neutral and low-level ionized gas metallicity in the GRB surroundings (e.g.

<figure><img src="image_6.png" /><figcaption>**Figure 4.** Comparison of the metallicities listed in Table 3 and the re-calculation of $Z_{abs}$ and both methods of obtaining $Z_{SF}(T_e)$. The solid line corresponds to $Z_{abs}$, whereas the shaded regions represent the $1\sigma$, $2\sigma$, and $3\sigma$ confidence regions in progressively lighter shades. Different calibrations are represented using different colours and marker styles, with the coloured (shorter) error bar representing the statistical uncertainty and the larger, dark grey error bar representing the full uncertainty including the systematic uncertainty in the SL diagnostics. The markers without coloured error bars are the values in Table 3 presented without the errors because the peak of the diagnostic was outside of the $1\sigma$ error of the line ratio, the dark grey error bars represent the systematic uncertainty in the calibrations in these cases. In cases where it was not possible to discriminate between the lower or upper branch, we plot both metallicity solutions. For a given line ratio the data points corresponding to different calibrations have been slightly offset to each other for clarity.</figcaption></figure>

Krühler et al. 2017; Wiseman et al. 2017). Typically, the closest absorbing clouds have been found to lie at a few hundred parsec from the GRB (Vreeswijk et al. 2007, 2013; D’Elia et al. 2014; although see Saccardi et al. 2023). Using GRB absorption spectra therefore ensures we have two metallicity measurements along the same line of sight, probing the same region of the galaxy, allowing for a comparison between $Z_{SF}$ and $Z_{abs}$ in the same region. We are unsure whether the metallicity of the ISM in the neutral and ionized phase is comparable, and our JWST data allow us to examine this. Schady et al. (2024) investigated the relation between $Z_{abs}$ and $Z_{SF}$(SL), but in this work, for the first time, we can compare the metallicity of both gas phases using direct measurements.

Fig. 4 shows all emission line metallicities listed in Table 3 and the $T_e$-based metallicities listed in Table 2 for comparison. $Z_{abs}$ is indicated by the solid grey line, with progressively lighter shaded regions corresponding to the $1\sigma$, $2\sigma$, and $3\sigma$ uncertainty region, respectively. When comparing the different strong line metallicities in Fig. 4, we can see that there is a wide spread in metallicities we find from the different SL diagnostics, both within the same calibration sample (marked with the same colour and marker) and between different calibration samples. This is a common issue when using SL diagnostics, with variations as large as $\sim 0.6$ dex between different diagnostics reported before (e.g. Kewley & Ellison 2008; Teimoorinia et al. 2021). The SL relations have traditionally been calibrated on local samples of galaxies which may not be representative of early populations. For example, galaxies in the early universe have younger stellar populations and higher ionization parameters than local galaxies (e.g. Steidel et al. 2014). Since the launch of JWST, there have been efforts to calibrate these relations for ISM conditions in high-$z$ galaxies (e.g. Hirschmann, Charlot & Somerville 2023; Laseter et al. 2024; Sanders et al. 2024), but these are based on small samples and even for the high-$z$ calibrations

<footnote n="4">⁴https://cigale.lam.fr/</footnote>
<figure><img src="image_7.png" /><figcaption>**Figure 5.** Dust depletion fits to the neutral element relative abundances measured in the LRIS optical afterglow spectrum of GRB 050505 (Berger et al. 2006). We assume an uncertainty of 0.1 dex for all column densities. The dotted-dashed line corresponds to the best-fitting depletion pattern, which results in a best fit, dust-depletion corrected absorption metallicity of [M/H] = −1.03 ± 0.11.</figcaption></figure>

there is a spread in metallicities between the different line ratios of up to ~ 0.5 dex (e.g. Nakajima et al. 2022, 2023; Laseter et al. 2024; Sanders et al. 2024). We refer the reader to the literature on the differences in calibration samples and diagnostics, see e.g. Kewley & Ellison (2008), Maiolino & Mannucci (2019), Sanders et al. (2024), and Laseter et al. (2024) for extensive reviews, and refrain from commenting on what can be the cause of the differences between the obtained strong line metallicity values.

### 4.2.1 Absorption versus $T_e$-based metallicities

The afterglow spectrum used to obtain the absorption based metallicity of the host of GRB 050505 was obtained with the Low Resolution Imaging Spectrometer (LRIS) on the Keck I 10-m telescope. Since this is a low resolution instrument, the absorption lines used to calculate the metallicity can suffer from hidden saturation, and the metallicity should thus be considered a lower limit. The lower limit of $12 + \log(O/H) > 7.5$ presented in Berger et al. (2006; assuming a solar abundance $12 + \log(O/H) = 8.69$; Asplund et al. 2009) is consistent with the range in $T_e$-based metallicities that we measure ($12 + \log(O/H) = 7.80 - 7.96$; see Table 3).

To try and constrain better the absorption based metallicity, we re-calculated the metallicity following the procedure of Wiseman et al. (2017). This method uses multiple, singly ionized metal absorption lines to simultaneously constrain the dust depletion and neutral gas metallicity $Z_{\text{abs}}$, making use of the detailed depletion patterns from De Cia et al. (2016). Although the measured column densities likely suffer from some level of hidden saturation, by fitting all relative abundances simultaneously, we mitigate some of the uncertainties associated with low resolution absorption line measurements. Our best dust depletion fits to the relative abundances taken from Berger et al. (2006) are shown in Fig. 5 and give a best-fitting metallicity of [M/H] = −1.03 ± 0.11 corresponding to an oxygen abundance $12 + \log(O/H) = 7.66 ± 0.11$. Berger et al. (2006) state that S II and Ni II are likely not saturated, which is consistent with the relative abundances of these two species lying above the best-fitting dust depletion model shown in Fig. 5. In such a case, the relative abundances that lie below the line of best fit should be considered

lower limits. Nevertheless, the consistency between the model and all data points gives some validity to the absorption metallicity that we measure.

Interestingly, our absorption line metallicity is consistent within errors with the two $T_e$-based metallicities we measure (see Fig. 4). If the absorption line metallicity were considerably larger than what we measure, the implication would be that the neutral phase ISM is more enriched than the gas within SF regions, contrary to theoretical expectations (e.g. Metha & Trenti 2020; Metha, Cameron & Trenti 2021; Arabsalmani et al. 2023).

As shown in Fig. 4, the R23$_{SST24}$ diagnostic and the lower branch solution of R3$_{SST24}$ are also consistent with this improved value of the absorption metallicity within $1\sigma$, as well as the R3$_{NOX22}$ diagnostic. We note that while the $Ne3O2_{NOX22}$ is consistent with $Z_{\text{abs}}$, this is a data point plotted without error, because the line ratio was more than $1\sigma$ below the minimum value applicable for the diagnostic. Additionally, the relation between $Ne3O2$ and metallicity is almost flat (see Fig. B1), and thus insensitive to changes in the line ratio. We therefore do not consider this a reliable diagnostic. R23$_{NOX22}$ is consistent at $1.2\sigma$ and while this is not quite $1\sigma$ significance, it is still notably more consistent than the other diagnostics not mentioned already.

### 4.2.2 $T_e$-based versus strong line metallicities

Comparing the different SL diagnostics plotted in Fig. 4 to the two $T_e$-based metallicities, we see that the R23 and R3 diagnostics generally agree best. While most, if not all, of the SL diagnostics are technically consistent with the $T_e$-based metallicities due to the large systematic uncertainties in the calibrations (the grey errorbars), most diagnostics result in metallicities higher than the $T_e$-based metallicity.

The R23 diagnostic is relatively independent of the ionization parameter because it uses both the singly and doubly ionized lines. Although not completely independent (see e.g. Kewley & Dopita 2002), we do generally see it agrees better with our value of $Z_{\text{SF}}(T_e)$ than the diagnostics heavily dependent on the ionization parameter, such as N2 and S2 which only use either just the singly or just the doubly ionized ions of one species. We do note that because of the spread in wavelengths in the emission lines needed for the R23 diagnostic, it is more sensitive to the reddening correction used compared to diagnostics that use emission lines closer together in wavelength.

The NOX22 R23 and R3 high-EW diagnostics as presented in Table 3 and plotted in Fig. 4 are consistent with $Z_{\text{SF}}(T_e)$ within $1\sigma$, indicating that the high-EW relations are the best calibration for high-z galaxies presented by NOX22, as also suggested by Nakajima et al. (2023). When using the averaged R23 and R3 relations from NOX22, the agreement is also better than the other diagnostics, but considering the EW dependence improves both diagnostics further compared to the $T_e$-based metallicity. Interestingly, the LMC24 $\hat{R}$ diagnostic deemed best by Schady et al. (2024) for the rest of the GRB host galaxy sample only barely agrees with $T_e$ within $1\sigma$ and does not agree with $Z_{\text{abs}}$.

### 4.2.3 The N/O–O/H relation

The N/O–O/H relation in the local universe shows a relatively flat relation at low metallicities that then starts increasing as a power law at $12 + \log(O/H) \sim 8.0$ with the onset of secondary N production (e.g. Edmunds & Pagel 1978; Henry & Worthey 1999; Köppen & Hensler 2005; Vincenzo et al. 2016). With JWST, some high redshift
galaxies have been observed to have surprisingly high N/O ratios relatively to their metallicity (e.g. Cameron, Katz & Rey 2023; Marques-Chaves et al. 2024). We thus calculate log(N/O) for the host galaxy of GRB 050505 using various methods (see Table 2). Two of these methods (from Thurston et al. 1996 and Izotov et al. 2006) explicitly depend on the electron temperature, which is calculated using observed auroral/strong emission lines and fits to photoionization models. The other two methods (from Pilyugin et al. 2010 and Pilyugin & Grebel 2016) depend only on oxygen and nitrogen (and sulphur, in the case of Pilyugin et al. 2010) strong-line ratios, with empirically derived N/O relations fit to a sample of precisely selected H II regions. The various estimated upper limits range from log(N/O) < -0.97 to -0.66 and are thus consistent with the general trend between 12 + log(O/H) and log(N/O) seen in star-forming galaxies (e.g. Dopita et al. 2016; Nicholls et al. 2017), unlike other notable high-redshift systems such as GN-z11 (Cameron et al. 2023).

## 4.3 Mixing of metals

The consistency between $Z_{SF}(T_e)$ and $Z_{abs}$ within $1\sigma$ suggests that metals newly synthesized by stars are efficiently distributed within the SF regions (traced by $Z_{SF}(T_e)$) and the neutral ISM (traced by $Z_{abs}$). In order to investigate the expected differences between absorption and emission line metallicities Arabsalmani et al. (2023) used the EAGLE cosmological hydrodynamical simulations to study the predicted relation between the metallicity within SF regions and the metallicity along random sightlines as a function of galaxy and sightline properties. They found the closest agreement between the two probes for sightlines that crossed close to the galaxy centre, within 1–2 kpc, and this agreement improved further for sightlines that probed larger column densities. However, even for high column density and low radial offset sightlines, Arabsalmani et al. (2023) predicted a small offset of the order of ~0.2 dex between $Z_{abs}$ and $Z_{SF}$, with $Z_{SF}$ being the higher value of the two. The biggest difference was found when the simulated sightlines were at large radial offsets from the galaxy centre, which can be understood if the outskirts of galaxies are less enriched in metals than the galaxy disc, where the majority of star formation (and thus nucleosynthesis) occurs. The consistency that we measure between $Z_{abs}$ and $Z_{SF}$ for the host galaxy of GRB 050505 is in agreement with the predictions from Arabsalmani et al. (2023), given the large hydrogen column density measured along the GRB line of sight ($\log(N_H)/\text{cm}^{-2} = 22.1$; Berger et al. 2006) and the small GRB positional offset from the galaxy centre (see Fig. 1).

Metha & Trenti (2023; whose work builds on Metha & Trenti 2020 and Metha et al. 2021) carried out a similar analysis, comparing results between a number of cosmological simulations (Illustris, IllustrisTNG, and EAGLE), and find similar conclusions that there is an offset between $Z_{abs}$ and $Z_{SF}$, for all three simulations. They also find that the difference between $Z_{abs}$ and $Z_{SF}$ increases when the metallicity decreases, in agreement with Arabsalmani et al. (2023), although Metha & Trenti (2023) do not consider the effect of impact parameter or the line of sight column density.

Instead Metha & Trenti (2023) considered the effect of introducing a metallicity cutoff in the GRB progenitor, and they found that the difference between $Z_{SF}$ and $Z_{abs}$ increasingly deviated for galaxies with $Z_{SF}$ larger than the imposed metallicity cutoff. This can be understood since GRBs with high metallicity hosts would be more likely to occur at large radial offsets, where the gas-phase metallicity is expected to be lower due to metallicity gradients. This therefore implies that finding $Z_{SF} > Z_{abs}$ from observations could be evidence

for the existence of a metallicity bias in GRB progenitors, although a large sample of $Z_{SF}$ and $Z_{abs}$ pairs would be required to convincingly detect such an offset.

## 5 SUMMARY AND CONCLUSIONS

In this paper, we present the first GRB host galaxy for which we have a metallicity measurement probing the warm and the cold ISM, for the first time allowing to bridge the gap between these two phases of the ISM. In our JWST/NIRSPEC spectra, we detect the [O III]λ4363 auroral line and use it to calculate the electron temperature of the emitting gas and hence the $T_e$-based metallicity from emission lines. This is the most direct, mostly model-independent method of determining the metallicity. Comparing it to the model dependent strong line metallicites and the non-flux limited GRB afterglow absorption based metallicity, we see the $T_e$-based metallicity seems to agree better with $Z_{abs}$, although the SL diagnostics calibrated on ISM conditions in the early universe do also agree with the $Z_{SF}(T_e)$. The agreement between $Z_{abs}$ and $Z_{SF}(T_e)$ suggests mixing between the neutral and ionized gas is efficient along the line of sight.

Using the GRB afterglow spectrum combined with the integrated spectrum eliminates the offset between where the two metallicities are measured, and therefore this cannot be the cause of the discrepancy between $Z_{SF}(\text{SL})$ and $Z_{abs}$ in this work. This leaves a physical reason, or a systematic error in the calibrations of the SL diagnostics. We find the SL diagnostics independent from the ionization parameter (e.g. R23) or diagnostics where a dependency on the ionization parameter is explicitly included (as in NOX22) agree better with our measurements of $Z_{SF}(T_e)$. We therefore advocate for using these specific diagnostics when determining the metallicity for high-z galaxies. However, whenever possible, we suggest using $Z_{SF}(T_e)$ or $Z_{abs}$, since they are less dependent on models, calibration samples and additional parameters such as ionization.

Our improved $Z_{abs}$ is in good agreement with $Z_{SF}(T_e)$ and $Z_{SF}(\text{SL})$ when using the R23 diagnostic, which could imply that $Z_{abs}$ can be used to trace metallicity of SF regions in high-z galaxies. To confirm this result, and to investigate further if the $T_e$-based metallicity indeed traces closest the neutral gas metallicity obtained through GRB absorption line spectra, the sample of high-z GRB host galaxies with detections of the [O III]λ4363 auroral emission lines has to be expanded, although significant efforts have been made over the last few years. If indeed confirmed with a large sample, our results could imply that GRB absorption spectroscopy can be used to trace cosmic chemical evolution to the earliest cosmic epochs and for galaxies too faint for emission line spectroscopy, even using JWST.

## ACKNOWLEDGEMENTS

This work is based on observations made with the NASA/ESA/CSA James Webb Space Telescope. The data were obtained from the Mikulski Archive for Space Telescopes at the Space Telescope Science Institute, which is operated by the Association of Universities for Research in Astronomy, Inc., under NASA contract NAS 5-03127 for JWST. These observations are associated with program #2344. This research is based on observations made with the NASA/ESA Hubble Space Telescope obtained from the Space Telescope Science Institute, which is operated by the Association of Universities for Research in Astronomy, Inc., under NASA contract NAS 5-26555. These observations are associated with program #15644. AI and PS acknowledge support from the UK Science and Technology Facilities Council, grant reference ST/X001067/1. PW acknowledges support from the UK Science and Technology Facilities Council,
grant reference ST/Z510269/1. RGB acknowledges financial support from the Severo Ochoa grant CEX2021-001131-S funded by MCIN AEI/10.13039/501100011033 and PID2022-141755NB-I00. RLCS acknowledges support from the Leverhulme Trust grant RPG-2023-240. AR acknowledges support from PRIN-MIUR 2017 (grant 20179ZF5KS). Funded by the Deutsche Forschungsgemeinschaft (DFG, German Research Foundation) under Germany's Excellence Strategy-EXC 2094-390783311. SDV acknowledges the support of the French Agence Nationale de la Recherche (ANR), under grant ANR-23-CE31-0011 (project PEGaSUS). This work makes use of Python packages NUMPY (v1.26.4; Harris et al. 2020), UNCERTAINTIES (v3.2.2; http://pythonhosted.org/uncertainties/), MATPLOTLIB (v3.9.1; Hunter 2007), GDPYC (v1.1; https://gdpyc.readthedocs.io/en/latest/) and LMFIT (v1.3.2; Newville et al. 2016). This work made use of Astropy (v6.1.2; http://www.astropy.org): a community-developed core Python package and an ecosystem of tools and resources for astronomy (Astropy Collaboration 2013, 2018, 2022).

DATA AVAILABILITY

The JWST and HST data are publicly available through the MAST archive (https://stdatu.stsci.edu/datadownloads.html) under program #2344 with PI P. Schady and #15644 with PI D. Perley, respectively. The data described here may also be obtained from the MAST archive at https://dx.doi.org/10.17909/ektj-8179. Code used for this analysis will be made available on reasonable request to the corresponding author.

REFERENCES

Arabsalmani M. et al., 2018, MNRAS, 473, 3312
Arabsalmani M. et al., 2023, ApJ, 952, 67
Arellano-Córdova K. Z. et al., 2022, ApJ, 940, L23
Asplund M., Grevesse N., Sauval A. J., Scott P., 2009, ARA&A, 47, 481
Astropy Collaboration, 2013, A&A, 558, A33
Astropy Collaboration, 2018, AJ, 156, 123
Astropy Collaboration, 2022, apj, 935, 167
Berger E., Penprase B. E., Cenko S. B., Kulkarni S. R., Fox D. B., Steidel C. C., Reddy N. A., 2006, ApJ, 642, 979
Bolmer J. et al., 2019, A&A, 623, A43
Boquien M., Burgarella D., Roehlly Y., Buat V., Ciesla L., Corre D., Inoue A. K., Salas H., 2019, A&A, 622, A103
Bushouse H. et al., 2025, JWST Calibration Pipeline, Zenodo
Cameron A. J., Katz H., Rey M. P., 2023, MNRAS, 522, L89
Cardelli J. A., Clayton G. C., Mathis J. S., 1989, ApJ, 345, 245
Chabrier G., 2003, PASP, 115, 763
Christensen L., Hjorth J., Gorosabel J., 2004, A&A, 425, 913
Christensen L. et al., 2012, MNRAS, 427, 1973
Cucchiara A., Fumagalli M., Rafelski M., Kocevski D., Prochaska J. X., Cooke R. J., Becker G. D., 2015, ApJ, 804, 51
Curti M. et al., 2023, MNRAS, 518, 425
Curti M. et al., 2024, A&A, 684, A75
D'Elia V. et al., 2014, A&A, 564, A38
De Cia A., Ledoux C., Mattsson L., Petitjean P., Srianand R., Gavignaud I., Jenkins E. B., 2016, A&A, 596, A97
De Cia A., Ledoux C., Petitjean P., Savaglio S., 2018, A&A, 611, A76
Decleir M. et al., 2022, ApJ, 930, 15
Dopita M. A., Kewley L. J., Sutherland R. S., Nicholls D. C., 2016, Ap&SS, 361, 61
Edmunds M. G., Pagel B. E. J., 1978, MNRAS, 185, 77P
Fitzpatrick E. L., Massa D., Gordon K. D., Bohlin R., Clayton G. C., 2019, ApJ, 886, 108
Friis M. et al., 2015, MNRAS, 451, 167
Fynbo J. P. U. et al., 2010, MNRAS, 408, 2128
Fynbo J. P. U. et al., 2011, MNRAS, 413, 2481

Fynbo J. P. U. et al., 2013, MNRAS, 436, 361
Galama T. J. et al., 1998, Nature, 395, 670
Gordon K., 2024, dust_extinction, Zenodo
Gordon K. D., Cartledge S., Clayton G. C., 2009, ApJ, 705, 1320
Gordon K. D. et al., 2021, ApJ, 916, 33
Gordon K. D., Clayton G. C., Decleir M., Fitzpatrick E. L., Massa D., Misselt K. A., Tollerud E. J., 2023, ApJ, 950, 86
Graham J. F., Fruchter A. S., 2013, ApJ, 774, 119
Graham J. F., Fruchter A. S., 2017, ApJ, 834, 170
Graham J. F., Schady P., Fruchter A. S., 2023, ApJ, 954, 13
Harris C. R. et al., 2020, Nature, 585, 357
Hartoog O. E. et al., 2015, A&A, 580, A139
Heintz K. E. et al., 2023, ApJ, 944, L30
Henry R. B. C., Worthey G., 1999, PASP, 111, 919
Hirashita H., Buat V., Inoue A. K., 2003, A&A, 410, 83
Hirschauer A. S., Salzer J. J., Bresolin F., Saviane I., Yegorova I., 2015, AJ, 150, 71
Hirschmann M., Charlot S., Somerville R. S., 2023, MNRAS, 526, 3504
Hjorth J. et al., 2003, Nature, 423, 847
Hunter J. D., 2007, Comput. Sci. Eng., 9, 90
Izotov Y. I., Stasi'nskastasi'nska G., Meynet G., Guseva N. G., Thuan T. X., 2006, A&A, 448, 955
Izzo L. et al., 2017, MNRAS, 472, 4480
Kawai N. et al., 2006, Nature, 440, 184
Kennicutt R. C. Jr, 1998, ARA&A, 36, 189
Kewley L. J., Dopita M. A., 2002, ApJS, 142, 35
Kewley L. J., Ellison S. L., 2008, ApJ, 681, 1183
Kewley L. J., Maier C., Yabe K., Ohta K., Akiyama M., Dopita M. A., Yuan T., 2013a, ApJ, 774, L10
Kewley L. J., Dopita M. A., Leitherer C., Davé R., Yuan T., Allen M., Groves B., Sutherland R., 2013b, ApJ, 774, 100
Köppen J., Hensler G., 2005, A&A, 434, 531
Krogager J.-K. et al., 2013, MNRAS, 433, 3091
Krühler T. et al., 2015, A&A, 581, A125
Krühler T., Kuncarayakti H., Schady P., Anderson J. P., Galbany L., Gensior J., 2017, A&A, 602, A85
Laseret I. H. et al., 2024, A&A, 681, A70
Maiolino R., Mannucci F., 2019, A&AR, 27, 3
Marques-Chaves R. et al., 2024, A&A, 681, A30
McGuire J. T. W. et al., 2016, ApJ, 825, 135
Metha B., Trenti M., 2020, MNRAS, 495, 266
Metha B., Trenti M., 2023, MNRAS, 520, 879
Metha B., Cameron A. J., Trenti M., 2021, MNRAS, 504, 5992
Nakajima K. et al., 2022, ApJS, 262, 3
Nakajima K., Ouchi M., Isobe Y., Harikane Y., Zhang Y., Ono Y., Umeda H., Oguri M., 2023, ApJS, 269, 33
Neeleman M., Wolfe A. M., Prochaska J. X., Rafelski M., 2013, ApJ, 769, 54
Newville M., Stensitzki T., Allen D. B., Rawlik M., Ingargiola A., Nelson A., 2016, Astrophysics Source Code Library, record ascl:1606.014
Nicholls D. C., Dopita M. A., Sutherland R. S., Kewley L. J., Palay E., 2013, ApJS, 207, 21
Nicholls D. C., Dopita M. A., Sutherland R. S., Jerjen H., Kewley L. J., Basurah H., 2014, ApJ, 786, 155
Nicholls D. C., Sutherland R. S., Dopita M. A., Kewley L. J., Groves B. A., 2017, MNRAS, 466, 4403
Osterbrock D. E., 1989, Astrophysics of Gaseous Nebulae and Active Galactic Nuclei. University Science Books, Mill Valley, CA
Osterbrock D. E., Ferland G. J., 2006, Astrophysics of Gaseous Nebulae and Active Galactic Nuclei, 2nd edn. University Science Books, Mill Valley, CA
Palmerio J. T. et al., 2019, A&A, 623, A26
Patrício V., Christensen L., Rhodin H., Cañamas R., Lara-López M. A., 2018, MNRAS, 481, 3520
Peimbert M., 1967, ApJ, 150, 825
Perley D. A. et al., 2016, ApJ, 817, 8
Péroux C., Howk J. C., 2020, ARA&A, 58, 363
Pettini M., Ellison S. L., Steidel C. C., Bowen D. V., 1999, ApJ, 510, 576
Pilyugin L. S., Grebel E. K., 2016, MNRAS, 457, 3678

Pilyugin L. S., Vílchez J. M., Thuan T. X., 2010, ApJ, 720, 1738

Piranomonte S. et al., 2015, MNRAS, 452, 3293

Planck Collaboration XIII, 2016, A&A, 594, A13

Popesso P. et al., 2023, MNRAS, 519, 1526

Prochaska J. X., Gawiser E., Wolfe A. M., Cooke J., Gelino D., 2003a, ApJS, 147, 227

Prochaska J. X., Castro S., Djorgovski S. G., 2003b, ApJS, 148, 317

Prochaska J. X. et al., 2004, ApJ, 611, 200

Prochaska J. X. et al., 2007a, ApJS, 168, 231

Prochaska J. X., Chen H.-W., Dessauges-Zavadsky M., Bloom J. S., 2007b, ApJ, 666, 267

Rafelski M., Wolfe A. M., Prochaska J. X., Neeleman M., Mendez A. J., 2012, ApJ, 755, 89

Rhoads J. E. et al., 2023, ApJ, 942, L14

Rhodin N. H. P., Christensen L., Møller P., Zafar T., Fynbo J. P. U., 2018, A&A, 618, A129

Rogers N. S. J., Skillman E. D., Pogge R. W., Berg D. A., Croxall K. V., Bartlett J., Arellano-Córdova K. Z., Moustakas J., 2022, ApJ, 939, 44

Saccardi A. et al., 2023, A&A, 671, A84

Sanders R. L. et al., 2020, MNRAS, 491, 1427

Sanders R. L. et al., 2021, ApJ, 914, 19

Sanders R. L., Shapley A. E., Topping M. W., Reddy N. A., Brammer G. B., 2024, ApJ, 962, 24

Savaglio S., 2006, New J. Phys., 8, 195

Schady P. et al., 2007, MNRAS, 377, 273

Schady P. et al., 2024, MNRAS, 529, 2807

Schaerer D., Marques-Chaves R., Barrufet L., Oesch P., Izotov Y. I., Naidu R., Guseva N. G., Brammer G., 2022, A&A, 665, L4

Schlaflay E. F., Finkbeiner D. P., 2011, ApJ, 737, 103

Schlegel D. J., Finkbeiner D. P., Davis M., 1998, ApJ, 500, 525

Schneider B., Le Floc'h E., Arabsalmani M., Vergani S. D., Palmerio J. T., 2022, A&A, 666, A14

Scholte D. et al., 2025, MNRAS, 540, 1800

Schulze S. et al., 2015, ApJ, 808, 73

Shi W.-B. et al., 2014, Res. Astron. Astrophys., 14, 875

Starling R. L. C. et al., 2005, A&A, 442, L21

Starling R. L. C. et al., 2011, MNRAS, 411, 2792

Stasińska G., Izotov Y., 2003, A&A, 397, 71

Stasińska G. et al., 2012, EAS Publ. Ser. Vol. 54, Oxygen in the Universe. Cambridge Univ. Press, Cambridge

Stasińska G., Izotov Y., Morisset C., Guseva N., 2015, A&A, 576, A83

Steidel C. C. et al., 2014, ApJ, 795, 165

Storey P. J., Zeippen C. J., 2000, MNRAS, 312, 813

Strom A. L., Steidel C. C., Rudie G. C., Trainor R. F., Pettini M., 2018, ApJ, 868, 117

Tanvir N. R. et al., 2012, ApJ, 754, 46

Teimoorinia H., Jalilkhany M., Scudder J. M., Jensen J., Ellison S. L., 2021, MNRAS, 503, 1082

Thöne C. C. et al., 2013, MNRAS, 428, 3590

Thurston T. R., Edmunds M. G., Henry R. B. C., 1996, MNRAS, 283, 990

Trump J. R. et al., 2023, ApJ, 945, 35

Vergani S. D. et al., 2015, A&A, 581, A102

Vincenzo F., Belfiore F., Maiolino R., Matteucci F., Ventura P., 2016, MNRAS, 458, 3466

Vreeswijk P. M. et al., 2007, A&A, 468, 83

Vreeswijk P. M. et al., 2013, A&A, 549, A22

Wiersema K. et al., 2007, A&A, 464, 529

Wiseman P., Schady P., Bolmer J., Krühler T., Yates R. M., Greiner J., Fynbo J. P. U., 2017, A&A, 599, A24

Wolfe A. M., Gawiser E., Prochaska J. X., 2005, ARA&A, 43, 861

Woosley S. E., 1993, ApJ, 405, 273

Yates R. M., Schady P., Chen T. W., Schweyer T., Wiseman P., 2020, A&A, 634, A107

APPENDIX A: EMISSION LINE FITS

In Fig. A1, we show the best fits to the remaining strong lines detected in our galaxy spectra described in Section 3.1. The fluxes calculated from these fits are listed in Table 1.
<figure><img src="image_8.png" /><figcaption>**Figure A1.** As in Fig. 3, but for the remaining emission lines for the host of GRB 050505. The centroids of each fitted Gaussian are marked with a vertical dash and labelled. We note that we fit the [O II]λλ3726,3729 doublet with two individual Gaussians that blend into the line plotted in the first panel.</figcaption></figure>
<figure><img src="image_9.png" /></figure>

**Figure B1.** Relations between strong line ratios and metallicity. Different colours/linestyles represent different calibrations of the relations. The colours are the same as in Fig. 4. The purple, horizontal line is the measured strong line ratio labelled on the y-axis. The shaded purple regions are $1\sigma$, $2\sigma$, and $3\sigma$ errors on the strong line ratio. For $N_2$ and $O_3N_2$ only an upper or lower limit is determined, which is represented as the purple shaded area. The reported metallicities in Table 3 are the intersection points between the purple line and the various coloured lines. If the purple line lies outside the range of the calibrated relation, we give the maximum value of the curve as the corresponding value. For reference, the $T_e$-based metallicity we find is between $12 + \log(O/H) = 7.80\pm0.19$ and $7.96\pm0.21$.

## APPENDIX B: METALLICITY FITS

In Fig. B1, we plot the relations between ratios of the strong emission lines considered in this paper and $T_e$-based metallicity. Each panel represents a different strong line ratio and each different coloured line (and style) represents a different calibration sample. See Sections 3.2.2 of the main body of the paper for details on the line ratios and calibration samples used. The obtained metallicities are listed in Table 3.

<footnote n="1">¹Department of Physics, University of Bath, Claverton Down, Bath BA2 7AY, UK</footnote>

<footnote n="2">²School of Physics and Astronomy, University of Southampton, Southampton SO17 1BJ, UK</footnote>

<footnote n="3">³Centre for Astrophysics Research, University of Hertfordshire, Hatfield AL10 9AB, UK</footnote>

<footnote n="4">⁴Excellence Cluster ORIGINS, Boltzmannstraße 2, D-85748 Garching, Germany</footnote>

<footnote n="5">⁵Ludwig-Maximilians-Universität, Schellingstraße 4, D-80799 München, Germany</footnote>

<footnote n="6">⁶Niels Bohr Institute, University of Copenhagen, Jagtvej 128, DK-2200 N Copenhagen, Denmark</footnote>

<footnote n="7">⁷Cosmic Dawn Center (DAWN), University of Copenhagen, DK-2200 N Copenhagen, Denmark</footnote>

<footnote n="8">⁸Space Science Data Center (SSDC) – Agenzia Spaziale Italiana (ASI), I-00133 Roma, Italy</footnote>

<footnote n="9">⁹Department of Mathematics, Informatics, Physics and Earth Sciences, University of Messina, Viale F. S. D'Alcontres 31, I-98166 Messina, Italy</footnote>

<footnote n="10">¹⁰Instituto de Astrofísica de Andalucía – CSIC, Glorieta de la Astronomía s.n., E-18008 Granada, Spain</footnote>

<footnote n="11">¹¹Department of Physics & Astronomy, Clemson University, Kinard Lab of Physics, Delta Epsilon Ct, Clemson, SC 29634, USA</footnote>

<footnote n="12">¹²Centre for Astrophysics and Cosmology, Science Institute, University of Iceland, Dunhagi 5, 107 Reykjavík, Iceland</footnote>

<footnote n="13">¹³Department of Physics & Astronomy, University of Utah, Salt Lake City, UT 84112, USA</footnote>

<footnote n="14">¹⁴Department of Astrophysics/IMAPP, Radboud University Nijmegen, P.O. Box 9010, NL-6500 GL Nijmegen, the Netherlands</footnote>
¹⁵Department of Physics, University of Warwick, Gibbet Hill Road, Coventry
CV4 7AL, UK

¹⁶Anton Pannekoek Institute for Astronomy, University of Amsterdam, P.O.
Box 94249, NL-1090GE Amsterdam, the Netherlands

¹⁷INAF – Osservatorio di Astrofisica e Scienza dello Spazio, Via Piero Gobetti
93/3, I-40129 Bologna, Italy

¹⁸INAF – Istituto di Astrofisica Spaziale e Fisica Cosmica di Milano, Via A.
Corti 12, I-20133 Milano, Italy

¹⁹Physics Department, University of Calabria, I-87036 Rende, Italy

²⁰Laboratori Nazionali di Frascati, INFN (Istituto Nazionale di Fisica
Nucleare), Frascati, Italy

²¹INAF – Osservatorio Astronomico di Brera, Via Bianchi 46, I-23807
Merate, Italy

²²School of Physics and Astronomy, University of Leicester, University Road,
Leicester LE1 7RH, UK

²³LUX, Observatoire de Paris, Université PSL, CNRS, Sorbonne Université,
F-92190 Meudon, France

This paper has been typeset from a TEX/LATEX file prepared by the author.