We compute the large N limit of Wilson loop expectation values for a broad class of N=2 supersymmetric gauge theories defined on a general class of background three-manifolds M_3, diffeomorphic to S^3. We find a simple closed formula which depends on the background geometry only through a certain supersymmetric Killing vector field. The supergravity dual of such a Wilson loop is an M2-brane wrapping the M-theory circle, together with a complex curve in a self-dual Einstein manifold M_4, whose conformal boundary is M_3. We show that the regularized action of this M2-brane also depends only on the supersymmetric Killing vector, precisely reproducing the large N field theory computation.