  Mechanical resonators operating in the high-frequency regime have become a
versatile platform for fundamental and applied quantum research. Their
exceptional properties, such as low mass and high quality factor, make them
also very appealing for force sensing experiments. In this Letter, we propose a
method for detecting and ultimately controlling nuclear spins by directly
coupling them to high-frequency resonators via a magnetic field gradient.
Dynamical backaction between the sensor and an ensemble of nuclear spins
produces a shift in the sensor's resonance frequency, which can be measured to
probe the spin ensemble. Based on analytical as well as numerical results, we
predict that the method will allow nanoscale magnetic resonance imaging with a
range of realistic devices. At the same time, this interaction paves the way
for new manipulation techniques, similar to those employed in cavity
optomechanics, enriching both the sensor's and the spin ensemble's features.
