The Eph receptor tyrosine kinase (RTK) family is the largest subfamily of RTKs playing critical roles in many developmental processes such as tissue patterning, neurogenesis and neuronal circuit formation, angiogenesis, etc. How the 14 Eph proteins, via their highly similar cytoplasmic domains, can transmit diverse and sometimes opposite cellular signals upon engaging ephrins is a major unresolved question. Here, we systematically investigated the bindings of each SAM domain of Eph receptors to the SAM domains from SHIP2 and Odin, and uncover a highly specific SAM–SAM interaction-mediated cytoplasmic Eph-effector binding pattern. Comparative X-ray crystallographic studies of several SAM–SAM heterodimer complexes, together with biochemical and cell biology experiments, not only revealed the exquisite specificity code governing Eph/effector interactions but also allowed us to identify SAMD5 as a new Eph binding partner. Finally, these Eph/effector SAM heterodimer structures can explain many Eph SAM mutations identified in patients suffering from cancers and other diseases., eLife digest As an animal’s body develops, its cells need to find their way to the right place to form its tissues and organs. On top of this, nerve cells need to set up connections as they grow. A family of receptors called Eph receptors help to make this happen. They sit across cell membranes, waiting for signals from molecules called ephrins. Once activated, these receptors interact with other proteins inside the cell. There are 14 different Eph receptors, but the parts inside the cell are similar, with three domains arranged in a set order. Next to the membrane, there is a tyrosine kinase domain, an enzyme that can add a phosphate group to a protein. Then, there is a SAM domain, which interacts with other proteins. Finally, there is a PDZ domain binding motif, which anchors the receptor to the cell's internal skeleton. The similarity between the internal portions of the Eph receptors suggests that they should work in the same way. But, different receptors on the same cell, responding to the same external signal, can have opposite effects. Here, Wang et al. tested each of the 14 SAM domains to find out how this happens. SAM domains on Eph receptors interact with SAM domains on other proteins, including SHIP2 and Odin. Analysis of the interactions revealed specific patterns for each receptor. Even though SAM domains are similar in shape, their exact amino acids – the basic building blocks of proteins – differ at particular positions. This changes the way they interact, allowing them to bind to different partners. Wang et al. then used a technique called X-ray crystallography to reveal the three-dimensional structures of SHIP2 bound to EphA2 and Odin bound to EphA6, to see how the proteins interact in fine detail. It turns out that a piece of each Eph receptor called the “end helix” binds to a “mid-loop” structure in SHIP2 or Odin. Crucial amino acids in each ensure that these interactions are specific. Changing these critical positions prevented the proteins coming together or allowed them to bind to a completely different partner. The structures revealed the importance of negatively charged amino acids within the mid-loop of the Eph binding partners. Using this information, Wang et al. predicted and confirmed a brand-new interaction between EphA5 and one of the 127 SAM-containing proteins found in mice, a protein called SAMD5. Understanding the impact of protein structure on Eph receptors could aid research into human disease. Lastly, an analysis of a database containing genetic changes found in cancer patients revealed that many of the mutations occur inside SAM domains. Pinpointing the positions that affect Eph receptor binding could point the way to future treatments.