Abstract: Magnetic resonance techniques, e.g., nuclear magnetic resonance (NMR) and electron spin resonance (ESR), are used in a fluid sampling tool that extracts a fluid from subsurface earth formations into a flow channel within the tool. The magnetic resonance techniques involve applying a static magnetic field and an oscillating magnetic field to the fluid in the flow channel, and magnetic resonance signals are detected from the fluid and analyzed to extract information about the fluid such as composition, viscosity, etc.