We have conducted proton nuclear magnetic resonance (NMR) measurements of relaxation times and as well as the diffusion coefficient to detect and quantify gasoline, diesel, crude oil, and trichloroethylene (TCE) in sediment samples containing water. The sediment samples were coarse sand, fine sand, and a sand-clay mixture. We found that water, gasoline, diesel, and crude oil all exhibited similar signal amplitudes per unit volume, whereas TCE exhibited one-tenth the signal. The ability to use measurements to distinguish the contaminant signal from the water signal depended on the bulk-fluid properties as well as the sediment texture and grain size. In the distributions for samples containing equal volumes of contaminant and water, the contaminant signal could be resolved for crude oil in sand and for gasoline and TCE in the sand-clay mixture. Adding the diffusion measurement, using either pulsed or static gradients, made it possible to distinguish diesel and crude oil in all of the samples due to the large differences between the of the contaminants and water. From the diffusion measurements, we were able to accurately quantify diesel and crude oil volumes ranging from 1% to 17% of the total sample volume. These methods could be applied in the field using NMR logging tools to quantify and monitor subsurface contamination.