Nanoscale microwave imaging with a single electron spin in diamond

We report on imaging of microwave (MW) magnetic fields using a magnetometer based on the electron spin of a nitrogen vacancy center in diamond. We quantitatively image the magnetic field generated by high frequency (GHz) MW current with nanoscale resolution using a scanning probe technique. We demonstrate a MW magnetic field sensitivity in the range of a few nT/$\sqrt{\text{Hz}}$, polarization selection and broadband capabilities under ambient conditions and thereby establish the nitrogen vacancy center a versatile and high performance tool for the detection of MW fields. As a first application of this scanning MW detector, we determine the MW current density in a stripline and demonstrate a MW current sensitivity of a few nA/$\sqrt{\text{Hz}}$

We report on imaging of microwave (MW) magnetic fields using a magnetometer based on the electron spin of a nitrogen vacancy center in diamond. We quantitatively image the magnetic field generated by high frequency (GHz) MW current with nanoscale resolution using a scanning probe technique. Together with a shot noise limited MW magnetic field sensitivity of 680 nT/ √ Hz, our room temperature experiments establish the nitrogen vacancy center as a versatile and high performance tool for MW imaging, which furthermore offers polarization selectivity and broadband capabilities. As a first application of this scanning MW detector, we image the MW stray field around a stripline structure and thereby locally determine the MW current density with a MW current sensitivity of a few nA/ √ Hz.
Imaging and detecting MW fields constitutes a highly relevant element for engineering of future MW devices as well as for applications in atomic and solid state physics. For instance cavity quantum electrodynamics experiments with atoms [1,2] and superconducting qubits [3,4] or the coherent control of quantum magnets [5] and quantum dots [6] are based on manipulating quantum systems with MW electric or magnetic fields. Precise control and knowledge of the spatial distribution of the MW near field is thereby essential to achieve optimal device performance. Also, magnetic systems are known to exhibit a large variety of collective magnetic excitations, including spin waves [7] or excitations in frustrated magnets [8,9]. Imaging such magnetic excitations on the nanoscale is a crucial step towards their fundamental understanding and the development of new spintronics devices, such as magnonic waveguides [10] or domain wall racetrack memories [11]. As a consequence, various techniques have been designed to image MW electric and magnetic fields, including scanning near field microscopy [12][13][14], micro-Brillouin light scattering [15], superconducting quantum interference devices [16] or imaging with atomic vapor cells [17][18][19] or ultracold atoms [20]. With only a few exceptions [15], most of these techniques however lack a nanoscale spatial resolution or are restricted to operation in cryogenic or vacuum environments.
Microwave magnetic field imaging using the electronic spin of a single nitrogen vacancy (NV) center in diamond offers a promising alternative. The NV center is an optically active lattice point defect in diamond with a S = 1 ground state manifold. Its atomic size, exceptionally long coherence times, optical initialization and readout of the spin state make the NV center an ideal sensor for DC magnetic fields under ambient conditions [21][22][23][24][25]. Recently, magnetometry of MW magnetic fields has been demonstrated using a NV spin in bulk diamond [26], with a resulting MW magnetic field sensitivity of one µT/ √ Hz. However, the bulk NV centers employed in [26] severely restricted spatial resolution in imaging, and in particular do not allow for nanoscale imaging of MW near fields, which remains an outstanding challenge for NVbased MW imaging. In this letter, we address this issue and demonstrate the first nanoscale MW imaging using a scanning NV magnetometer [27]. Our proof-of-concept imaging experiments were performed on a prototypical MW circuit -a micron-scale MW stripline -and yield nanoscale resolution combined with shot noise limited MW magnetic field sensitivites in the range of a few hundred nT/ √ Hz. Our MW magnetic field detection is based on the ability of the MW field to drive coherent Rabi oscillations between the |0 and | ± 1 spin-states of the NV center (Fig.  1a)-c)). Selection rules impose that within the rotating wave approximation (RWA), the transition |0 → | ± 1 is only excited by a circularly polarized MW field σ ± . Due to the large NV spin splitting and the comparably weak microwave field amplitudes, the RWA holds to an extremely good extent in the experiments described here. An arbitrarily polarized MW field resonant with either the |0 → |+1 or |0 → |−1 transition therefore leads to an oscillation of the population between the two involved spin states, at a frequency Ω ± /2π = γ N V B ±,M W , where B ±,M W is the (right-) left-handed circularly polarized component of the MW field in a plane perpendicular to the NV axis and γ NV = 28 kHz/µT the NV gyromagnetic ratio. Measuring Ω ± by an appropriate experimental sequence (Fig. 1b)) thus allows one to directly determine the amplitude of the driving MW magnetic field in a circularly polarized basis (Fig. 1c)).
The NV spin we employ for MW imaging is located at the apex of an all diamond scanning probe (Fig.1d)), obtained in a series of fabrication steps, including low energy ion implantation, electron beam lithography and inductively coupled reactive ion etching [27]. In order to perform MW magnetic field imaging, the diamond scanning probe is integrated in a homebuilt combined confocal (CFM) and atomic force microscope (AFM) [27]. The AFM allows scanning of the NV spin in close proximity   1. a) Energy levels of the NV spin in a static magnetic field Bz. The |0 state exhibits a higher fluorescence than the | ± 1 states (bright and dark lightbulbs). b) Experimental pulse sequence employed for the measurement of NV Rabi oscillation. The first (second) readout pulse measures the fluorescence F (B −,MW ) (bare fluorescence F0) as described in the text. c) Optically detected Rabi oscillations of the NV spin, driven by a circular polarized MW magnetic field B −,MW in a static magnetic field of 1.6 mT (ωMW/2π = 2.825 GHz). The black dots are experimental data and the blue solid line corresponds to a fit with F (γNVB −,MW τ ) = F0(1 − C/2) + CF0/2 · cos 2πγNVB −,MW τ · e −τ /τ R , where F0 is the fluorescence in the |0 state, C is the amplitude and τR the decay time of the Rabi oscillations. (d) Schematic representation of the combined confocal and atomic force microscope. The all-diamond scanning probe containing the NV spin is scanned at a height d over the Pd stripline (yellow). The magnetic field generated by the current IMW which passes through the stripline is detected by the NV magnetometer. The NV spin is optically addressed using a homebuilt confocal microscope.
to a sample while the CFM is employed to optically read out the NV center spin state (Fig.1d)).
We demonstrate the performance of our MW magnetic field imaging on the MW stripline structure illustrated in Fig. 1d). The 2.5 µm wide MW stripline is patterned onto an undoped Si substrate covered with 300 nm of SiO 2 by electron beam lithography and evaporation of 60 nm of Pd. A MW source (Rhode&Schwarz SMB 100A) is used to drive a MW current I MW with a frequency in the GHz range through the stripline. The right-angled stripline we employ thereby generates a highly inhomogeneous MW magnetic field with a nontrivial field distribution which is largely linearly polarized [28]. This arrangement is therefore ideal to demonstrate spatial resolution and MW magnetic field sensitivity of our imager.
In the following, we demonstrate imaging of the σ −component of the MW magnetic field (ω MW /2π = 2.825 GHz) generated by the stripline. To that end, we tune the sensing frequency ω − /2π = 2.87 GHz −γ NV B z of the |0 → | − 1 transition via a static magnetic field B z to the frequency ω MW /2π of the MW field (see Fig. 1a)).
In analogy, the σ + -component of the MW magnetic field can in principle be adressed by changing the external magnetic field B z such that the |0 → | + 1 transition of the NV center is resonant with the frequency of the MW field to be imaged. However, we did not perform such an experiment, as for the device under test the MW magnetic field contains equal contributions of circular polarizations and would therefore not provide any polarization contrast in imaging [28].
In the first imaging mode, we perform imaging of equimagnetic field lines of constant amplitude B −,M W . For a fixed microwave pulse length τ 0 , the accumulated phase (pulse area) in the Rabi oscillation and thus the population difference between |0 and |−1 depends on the local microwave magnetic field B −,M W (Fig. 1b)-c)). While scanning the NV spin at a distance d over the stripline, one can therefore monitor variations of the microwave magnetic field via changes in the NV fluorescence F (Fig.  2). In order to correct for fluorescence changes arising from potential near field effects [27,29,30] while scanning, we simultaneously record the bare fluorescence rate   The versatility and stability of our microscope allows us to further image MW magnetic fields in all three dimensions and in particular as a function of distance to the sample. To that end, we release AFM force feedback and record the MW magnetic field image by scanning the sample in a plane orthogonal to the MW current ( Fig.  2b)). In analogy to Fig. 2a), we attribute a MW magnetic field amplitude to each isofield line as shown in Fig.  2b).
While providing a fast and straightforward method for nanoscale imaging of MW magnetic fields, our method for iso-field imaging suffers from limitations in regions of high magnetic field gradients. This is particularly appreciable near the edges of our stripline (Fig. 2a)), where individual field lines are hard to distinguish and identification of the measured isofield lines becomes intractable. In order to overcome this limitation, we extended our imaging capabilities to directly determine B −,M W at each point throughout the scan (Fig. 3). For this, we measured NV Rabi oscillations at each pixel in the scan range and determined B −,MW by a sinusodial fit to each of these traces. Fig. 3a) depicts the resulting image of B −,M W measured above the corner of the stripline imaged in Fig.  2a). From this data, we also extract iso-field lines as highlighted by grey solid lines in Fig. 3a). For the quantitative analysis of our results, which we provide below, we further used this imaging method to record linecuts of B −,MW as depicted in Fig. 3b) and c).
The measured distributions of B −,MW depends on the orientation (ϕ, θ) and the position r = (x, y, z) of the NV spin with respect to the MW current [28] (see also Fig. 1). Assuming an infinitely thin stripline (t w) in vacuum with a homogeneous MW current density J oriented parallel to the stripline, the MW magnetic field profiles in Fig. 3b) and c) can be described by an analytical function B −,MW (d, J, ϕ, θ) [28], with d, J, ϕ, θ as free parameters. We note that our assumption of a homogenous current distribution is justified by the fact that the skin-depth of Pd at 2.825 Ghz is larger than the striplinewidth and is further corroborated by our numerical simulations [28]. The resulting fits (blue lines in Fig. 3b) and c)) are in excellent agreement with the experimental data (dark grey dots in Fig. 3b) and c)). In addition, we have numerically computed in a finite element simulation the MW magnetic field amplitude, assuming a MW current in a stripline (width w = 2.5 µm, thickness t = 60 nm) on 300 nm of SiO 2 [28]. The best fit to the experimental data (green lines in Fig. 3a) and b)) is achieved with parameters d, J, ϕ, θ (green insets) that are almost identical to the analytical fit parameters (blue insets). Finally, we also numerically determined the full two dimensional distribution of the MW magnetic field in a finite element simulation (Fig. 3d)), using the distance and orientation of the NV spin determined in Fig. 3b) [28]. For most of the scanned area, the experimental data (Fig. 3a)) are in excellent agreement with the simulation (Fig. 3d)), which further establishes the reliability of our method.
The accurate determination of the NV-to-sample dis- , with the fit parameters and uncertainties [28] being indicated in blue. The green lines are the fits with a finite element simulation (see text), with the fit parameters shown accordingly. The orientation of the scanning probe is the same as in Fig 2b) and is identical for both linescans, resulting in a difference of 90 • for the azimuthal angle ϕ. The measurements have been performed at a frequency ωMW/2π = 2.825 GHz with a MW power of 7.5 dBm at the stripline input. d) Simulated 2D spatial distribution of the MW magnetic field amplitude B −,MW obtained by finite element computation of a 50 Ω stripline.
tance d = 25 ± 5 nm that our method provides is relevant for various aspects of our work and NV-based sensing in general. First and foremost, d determines the spatial resolution in imaging the sources of magnetic fields [27,31], which we thus estimate to be ∼ 25 nm. Moreover, the distance links the MW current in the stripline to the MW magnetic field seen by the NV spin and therefore sets the sensitivity with which one can detect a MW current in the sample. With d ∼ 25 nm and the magnetic field sensitivity determined below, we find a MW current sensitivity of our NV magnetometer of ∼ 300 nA/ √ Hz for an infinitely thin, current-carrying wire. Note that for the data set presented in Fig. 3c), we find d = 64±5 nm, significantly larger than the value of d = 25±5 nm, which we determine for all the other data presented in this work. We attribute this discrepancy to contaminations on the diamond tip that has accumulated throughout the course of our experiments [28] -removing these contaminants or working with a fresh tip should restore d to it's original value.
We now estimate the photon shot noise limited sensitivity of the NV spin determined by with F 0 , C and τ R as defined earlier (see Fig. 1 and Ref. [28]). For the NV spin used in our experiments, we find η photon = 680 nT/ √ Hz at 2.825 GHz [28]. It should be noted that in general the decay time of the Rabi oscillation τ R is itself a function of the Rabi frequency (and thus of B MW ) [32]. While a general expression for η photon is therefore difficult to obtain, it is instructive to consider the two limits of low and high Rabi frequencies with respect to 1/T * 2 , where the decay time is given by τ R = T * 2 and T 1 , respectively. For typical values of NV centers in ultrapure diamond (T * 2 ∼ 1 µs and T 1 ∼ 1 ms) one then finds η photon ∼ 1.4 µT/ √ Hz and η photon ∼ 40 nT/ √ Hz, respectively. Additionally, we note that while coherent detection of MW fields through Rabi oscillations is limited by τ R , incoherent detection of these fields is limited by T 1 only. Performing such incoherent MW imaging (also referred to as relaxation-imaging [33,34]) would thus allow us to reach the highest sensitivities also in the limit of low Rabi frequencies. The sensitivity could be further enhanced by improving the Rabi decay time τ R using isotopically enriched diamond [21,35] and by optimizing the photon collection efficiency using alternative tip geometries [36] or scanning probes made from [111] oriented diamond material [37]. In addition, the MW magnetic field sensitivity can be estimated from the full, quantitative field measurement (Fig. 3) and is given by η meas = δB -,MW √ T , where δB -,MW is the smallest measurable MW magnetic field, i.e. the fitting error to the Rabi fits, and T the measurement time for each data point. For the values extracted from Fig. 3 we obtain a sensitivity of η meas = 15 µT/ √ Hz [28], which is larger than the shot-noise limited sensitivity quoted above. This discrepancy is explained by the fact that for the measurement shown in Fig. 3, we recorded full Rabi oscillations for each point of the scan, i.e. most of the data was taken for evolution times τ , which do not yield optimal measurement sensitivities [28].
In conclusion, we have established scanning NV center spins as a valuable resource to sensitively detect and image MW magnetic fields on the nanoscale. Our results indicate an imaging resolution of ∼ 25 nm together with a shot noise limited MW magnetic field sensitivity of 680 nT/ √ Hz, resulting in a sensitivity to the generating currents of few nA/ √ Hz, all at frequencies ∼ 3 GHz. Extending the bandwidth of detection to the range above 20 GHz can be achieved by placing our microscope in a sufficiently strong magnetic field [38] and would have profound impact for applications in MW device characterization, as currently available field imaging techniques cannot operate in this frequency range [39]. It should be noted that detection of microwave fields through Rabi oscillations has also been implemented for 87 Rb vapor cells [17][18][19][20]. Such devices operate with tens of µm spatial resolution over a mm to cm detection window [40], compared to our nanoscale spatial resolution over a tens of µm detection window, and thus provide a complementary wide field imaging tool to our NV scanning magnetometers. Finally, recent experiments have demonstrated that spin wave excitations in nanomagnetic systems can be adressed via MW NV magnetometry [41]. There external DC magnetic fields are used to bring the spin wave excitation frequency into resonance with the NV spin transition and thus enables a detection of the spin wave amplitude via the NV Rabi frequency. Combining this detection scheme with our ability to image MW magnetic fields at nanoscale resolution would therefore form an exciting avenue that could allow for real space imaging of spin wave excitation in nanomagnets [42] or skyrmion core dynamics [43].

ACKNOWLEDGMENTS
We gratefully acknowledge financial support through the NCCR QSIT, a competence center funded by the Swiss NSF, and through SNF Grant No. As described in the manuscript, the MW current I M W in the stripline generates a linearly polarized, MW magnetic field B MW ( r) cos (ω MW t) with a frequency ω MW in the GHz range at the position of the NV spin r = (x, y, z). In the following we will assume a fixed frequency ω MW and position in space r = (x, y, z). For simplicity, we neglect the frequency component and suppress the dependency on r in the notation. We have The projection of the MW magnetic field on the NV axis is given by where R (ϕ, θ) corresponds to the transformation from the laboratory {x,y,z} to the reference frame {x',y',z'} defined by the NV axis e z . The transformation matrix holds where ϕ is the angle between the NV spin axis e z and the MW current direction I MW in the stripline plane (xy plane) and θ the angle with the surface normal of the stripline (z axis) (see Fig. 2a  The dependance on the orientation (ϕ, θ) of the NV spin has been omitted in the notation for the sake of simplicity. The NV spin is coherently manipulated by the MW magnetic field component B ⊥,MW orthogonal to the NV spin axis. This orthogonal component is linearly polarized and can be written as where B −(+),MW corresponds to the right (left) handed circular MW polarization component σ −(+) . The amplitude of the right (left) handed polarization is defined as follows Reminder: The MW magnetic field polarization B ∓,MW depends on the position r = (x, y, z) and the orientation (ϕ, θ) of the NV spin, which has been omitted in the notation for the sake of simplicity.

SPATIAL DISTRIBUTION OF MW MAGNETIC FIELD: FINITE ELEMENT SIMULATION
In the following section, we compute the MW magnetic field using a finite element simulation (RF module, COMSOL Multiphysics). We assume a 50 Ω Pd stripline (width w = 2.5 µm, thickness t = 60 nm) patterned on an undoped Si substrate covered by 300 nm of SiO 2 surrounded by air. A current signal I MW = I p sin ω MW t is applied at the input of the stripline, while the other end is being grounded (Fig. 4a). We use a frequency ω MW = 2.825 GHz and an excitation current of I p = 10 mA, which corresponds to a MW power of P RF = 7 dBm. The latter is close to the estimated power used in the experiment.
We first compute the MW current density J MW ( r) at each position r in the laboratory frame for the given frequency ω MW (Fig. 4a). The MW current density is homogeneous in the MW stripline, except at the right angled bends of the conductor. It should be noted that the skin effect can be neglected, as the skin depth of palladium (δ = 3.5 µm at 2.825 GHz) is larger than the width and thickness of the MW stripline.
The MW magnetic field B MW ( r) can then be calculated from the current density and transformed into a σ − MW polarization using Eq. 4 and 6. The obtained σ − polarization of the MW magnetic field is in excellent agreement with the 1D profiles in Fig. 3b and c of the main text. Also the simulated 2D MW field distribution in a xy plane 25 nm above the stripline (Fig. 3d main text) is in good agreement with the experiment (Fig. 3a main text). Differences  Figure 5b in an xy plane 25 nm above the surface of the stripline, is on the order of a few hundred nT and therefore smaller than the smallest detectable MW field (see last section of the supporting material). The MW magnetic field is therefore mostly linearly polarized for this particular stripline geometry and consequently we did not measure the σ + polarization in our experiment. However, we would like to emphasize that such a measurement is straightforward and can in principle be performed by tuning the sensing frequency to |0 → | + 1 transition of the NV center as described in the main text.

Magnetic vector potential and field of a stripline
In the following we provide an analytical expression for the MW magnetic field generated by the MW current in a stripline, which has a thickness t = 60 nm much smaller than its width w = 2.5 µm. The stripline can be considered as an infinitely thin wire and according to the finite element simulation in the previous section we can assume a homogeneous MW current density, except at the right angled bend of the MW conductor. For the straight part of the MW conductor aligned for example along the y direction, we therefore have a homogeneous current density J = (0, J y = J, 0) and the problem can be treated in the two dimensional xz plane. We neglect also the substrate and therefore assume an infinitely thin MW stripline in vacuum. The NV spin is located at a position (x, d + t/2). From Poisson's equation, we calculate the magnetic vector potential oriented in y direction where r = (x, d + t/2) are the coordinates of the NV spin where A y is evaluated and r = (x , z ) the coordinates of the MW current density in the wire. Equation 7 can be evaluated in analogy to an electrostatic potential with a charge distribution ρ (x , z ) where r 0 is an integration constant. Consequently Eq. 7 therefore becomes Following the assumption of the infinitely thin wire, the integration over z amounts to J · t. With integration boundaries as depicted in Fig. 6 the magnetic potential reduces to The corresponding MW magnetic field is determined from MW magnetic field projection on NV axis B MW ( r, J, ϕ, θ) and determination of σ− polarization component The MW magnetic field projected on the NV axis can be calculated by inserting Eq. 11 into Eq. 4 and yields With Eq.6 and 12, one can finally determine the polarization component σ − B −,MW ( r, J, ϕ, θ) = |B x,MW ( r, J, ϕ, θ) + iB y,MW ( r, J, ϕ, θ)| Considering r = (x, d + t/2), the MW magnetic field polarization depends on x, d, t, J, ϕ, θ. With the thickness being t = 60 nm and x the dependant variable, Eq. 13 can be used as a fitting function were the distance d, the MW current density J, and the angles ϕ and θ are free (fit) parameters. As demonstrated in the main text, fitting the experimental data with Eq. 13 shows an excellent agreement, confirming our initial assumptions that the substrate and the thickness of the stripline can be neglected. Finally, it should be noted that this analytical model is only valid under the assumption of a homogeneous current distribution and would not be accurate, for instance across the sharp bend of our MW conductor.
Determination and uncertainties of the fit parameters d, J, ϕ, θ The MW magnetic field amplitude B −,MW at a position r is determined in Fig. 3 of the main text by fitting the Rabi oscillations measured at this position (see main text). The corresponding Rabi fit function is given by where τ R is the Rabi decay time, γ NV the gyromagnetic ratio of the NV, τ the MW pulse duration and C a factor related to the contrast and F 0 the bare fluorescence. The MW magnetic field B −,MW yields a fit error δB -,R , depicted by the error bars in Fig. 3 of the main text. In a second step, the resulting MW magnetic field profile is fitted with the analytical function B −,MW (d, J, ϕ, θ) of Eq. 13. This fit gives the values p i for each parameter {d, J, ϕ, θ} with the corresponding fit error δp i,fit . The uncertainty of each p i is given by (i) the uncertainty of the Rabi fit δp i,R and (ii) the uncertainty δp i,fit of the fit with B −,MW (d, J, ϕ, θ) and yields In order to account for the uncertainty arising from the Rabi fit δp i,R , we fit the dataset B −,MW + δB -,R and B −,MW − δB -,R with Eq. 13. The fit then yields a parameter set p i,+ and p i,− , respectively. The uncertainty is given by The uncertainty δp i,fit can be directly extracted from the fit with Eq. 13. Tables I and II show the values and uncertainties of all parameters extracted in Fig. 3b    As discussed in the main text, the difference of ϕ between Tables I and II is fully consistent with the 90 • rotation of the MW current with respect to the scanning probe and the NV spin. The difference in the distance d can however be attributed to a spacing layer between the stripline and the scanning probe. Indeed, we observed the presence of a spacing layer at the end of the pillar on several diamond scanning probe used in magnetometry experiment (Fig.  7). The layer has a typical thickness of a few tens of nanometers and is most likely composed of organic material, for example residual resist or dust particles picked up somewhere on the sample surface during an AFM scan. It should be noted that metallic particles would lead to quenching of the NV fluorescence [30]. As we found no evidence for fluorescence quenching, we can therefore exclude a metallic spacing layer for the scanning probe used in this experiment. In this section, we illustrate the dependance on the distance and the NV spin orientation. We calculate the MW magnetic field B −,MW ( r, J, ϕ, θ) for different sets of parameters. As the MW current density is directly proportional to the MW magnetic field, we assume J = 4 mA/µm 2 as determined in Fig. 3 of the main text. Fig. 8 shows the evolution of the MW magnetic field profile along the x direction for different distance d of the NV spin to the stripline. As the distance d decreases, sharp peaks develop in the MW magnetic field close to the edge of the stripline, which can be understood in terms of stronger MW magnetic field gradients on the edge. In contrast to the distance d which only causes small modifications of the MW magnetic field close to the edge of the stripline, the orientation of the NV spin has a dramatic impact on the MW magnetic field profile ( Fig. 9 and Fig.  3 of the main text).

MW MAGNETIC FIELD SENSITIVITY
Photon shot noise limited sensitivity Moreover, we estimate the photon shot noise limited MW magnetic field sensitivity η photon . This sensitivity is given by where δB photon is the smallest MW magnetic field obtained for a signal-to-noise ratio of 1 and T the measurement time. In our experiment, the signal is defined as S = F 0 (1 − C/2) + CF 0 /2 · cos 2πγ NV δB photon τ · e −τ /τR (18) where τ R is the Rabi decay time, γ NV the gyromagnetic ratio of the NV, τ the MW pulse duration and C = (F 0 −F 1 )/F 0 the fluorescence contrast between the |0 and the |1 state and F 0 (F 1 ) the fluorescence (in counts per shot) in the |0 state (|1 state). For small values of the accumulated phase Φ = 2πγ NV δB photon τ [23], the signal can be approximated by In order to obtain maximum signal and thus optimal sensitivity, the signal has to be evaluated at τ = τ R /2 [21]. For a signal to noise ratio of 1 and assuming photon shot noise of √ F 0 a minimal field of can be calculated. It should be noted that the measurement time for a single shot experiment is equivalent to τ = τ R /2. During a total measurement time of T , T /τ = 2T /τ R repetitions of a single shot measurement can thus be performed. In this case, the fluorescence F 0 (in counts per shot) scales to 2F 0 T /τ R and one finally obtains the shot noise limited sensitivity The value for C, F 0 and τ R are extracted from the Rabi fit (equation. 18) to the data in Fig. 1c of the main text and yield C = 0.095, F 0 = 0.045 counts/shot and τ R = 4 µs. The sensitivity therefore amounts to η photon = 680 nT/ √ Hz.

Measured sensitivity
The MW magnetic field sensitivity in our experiments is estimated from the quantitative MW magnetic field measurement in Fig. 3 of the main text. The sensitivity is defined by where δB -,MW is the smallest measurable MW magnetic field, i.e. the fitting error to the Rabi frequency and thus the MW magnetic field and T the measurement time for each data point. We obtain an average fitting error δB -,MW = 2 µT of for both the image in Fig. 3a and the linecuts in Fig. 3b and c. With a measurement time of T = 67 s we get a sensitivity η meas = 15 µT/ √ Hz, which is ∼ 20 times larger then the photon shot noise limited sensivitity. It should be noted that the shot noise limited sensitivity is calculated at the point of optimal signal to noise ratio during a Rabi oscillation measurement. Therefore, by measuring and fitting a complete Rabi oscillation we only obtain an averaged and lower overall sensitivity.