Endoplasmic reticulum aminopeptidase I (ERAP1) is involved in the final processing of peptide precursors to generate the N-termini of MHC class I-restricted epitopes. ERAP1 thus influences immunodominance and cytotoxic immune responses by controlling the peptide repertoire available for cell surface presentation by MHC molecules. To enable this critical role in antigen processing, ERAP1 trims peptides by a unique molecular ruler mechanism that turns on/off hydrolysis activity in a peptide-length and sequence dependent manner. Thus unlike other aminopeptidases, ERAP1 could recognize both the Nand C-termini of peptides in order to read the substrate's length. To exemplify and validate this molecular ruler mechanism, we have carried out crystallographic studies on molecular recognition of antigenic peptide's C-terminus by ERAP1. In this report, we have determined a 2.8 angstrom-resolution crystal structure of an intermolecular complex between the ERAPI regulatory domain and a natural epitope's C-terminus displayed in a fusion protein. It reveals the structural details of peptide's C-termini recognition by ERAP1. ERAP1 uses specificity pockets on the regulatory domain to bind the peptide's carboxyl end and side chain of the C-terminal anchoring residue. At the same time, flexibility in length and sequence at the middle of peptides is accommodated by a kink with minimal interactions with ERAP1. (C) 2016 Elsevier Ltd. All rights reserved.