  Superconducting coplanar waveguide resonators that can operate in strong
magnetic fields are important tools for a variety of high frequency
superconducting devices. Magnetic fields degrade resonator performance by
creating Abrikosov vortices that cause resistive losses and frequency
fluctuations, or suppressing superconductivity entirely. To mitigate these
effects we investigate lithographically defined artificial defects in
resonators fabricated from NbTiN superconducting films. We show that by
controlling the vortex dynamics the quality factor of resonators in
perpendicular magnetic fields can be greatly enhanced. Coupled with the
restriction of the device geometry to enhance the superconductors critical
field, we demonstrate stable resonances that retain quality factors $\simeq
10^5$ at the single photon power level in perpendicular magnetic fields up to
$B_\perp \simeq$ 20 mT and parallel magnetic fields up to $B_\parallel \simeq$
6 T. We demonstrate the effectiveness of this technique for hybrid systems by
integrating an InSb nanowire into a field resilient superconducting resonator,
and use it to perform fast charge readout of a gate defined double quantum dot
at $B_\parallel =$ 1 T.
