The covalent attachment of adenosine monophosphate (AMP) to proteins, a process called AMPylation (adenylylation), has recently emerged as a novel theme in microbial pathogenesis. Although several AMPylating enzymes have been characterized, the only known virulence protein with de-AMPylation activity is SidD from the human pathogen Legionella pneumophila. SidD de-AMPylates mammalian Rab1, a small GTPase involved in secretory vesicle transport, thereby targeting the host protein for inactivation. The molecular mechanisms underlying Rab1 recognition and de-AMPylation by SidD are unclear. Here, we report the crystal structure of the catalytic region of SidD at 1.6 Å resolution. The structure reveals a phosphatase-like fold with additional structural elements not present in generic PP2C-type phosphatases. The catalytic pocket contains a binuclear metal-binding site characteristic of hydrolytic metalloenzymes, with strong dependency on magnesium ions. Subsequent docking and molecular dynamics simulations between SidD and Rab1 revealed the interface contacts and the energetic contribution of key residues to the interaction. In conjunction with an extensive structure-based mutational analysis, we provide in vivo and in vitro evidence for a remarkable adaptation of SidD to its host cell target Rab1 which explains how this effector confers specificity to the reaction it catalyses.