The "ham sandwich" theorem has been proven only for measures that are absolutely continuous with respect to Lesbeque measure. We prove a generalized version of the ham sandwich theorem which is applicable to arbitrary finite measures, and we give some sufficient conditions for uniqueness of the hyperplane identified by the theorem