Assembly of the HIV and other retroviruses is primarily driven by the oligomerization of the Gag polyprotein, the major viral structural protein capable of forming virus-like particles even in the absence of all other virally encoded components. Several critical determinants of Gag oligomerization are located in the C-terminal domain of the capsid protein (CA-CTD), which encompasses the most conserved segment in the highly variable Gag protein called the major homology region (MHR). The CA-CTD is thought to function as a dimerization module, although the existing model of CA-CTD dimerization does not readily explain why the conserved residues of the MHR are essential for retroviral assembly. Here we describe an x-ray structure of a distinct domain-swapped variant of the HIV-1 CA-CTD dimer stabilized by a single amino acid deletion. In the domain-swapped structure, the MHR-containing segment forms a major part of the dimerization interface, providing a structural mechanism for the enigmatic function of the MHR in HIV assembly. Our observations suggest that swapping of the MHR segments of adjacent Gag molecules may be a critical intermediate in retroviral assembly.