The key hydrolytic enzymes of the endocannabinoid system, fatty acid amide hydrolase (FAAH) and monoacylglycerol lipase (MAGL), are potential targets for various therapeutic applications. In this paper, we present more extensively the results of our previous work on piperazine and piperidine carboxamides and carbamates as FAAH and MAGL inhibitors. The best compounds of these series function as potent and selective MAGL/FAAH inhibitors or as dual FAAH/MAGL inhibitors at nanomolar concentrations. This study revealed that MAGL inhibitors should comprise leaving-groups with a conjugate acid pKa of 8–10, while diverse leaving groups are tolerated for FAAH inhibitors.