Tissue-resident memory CD8+ T cells (TRM) constitute a major component of the immune-surveillance system in nonlymphoid organs. Local, noncognate factors are both necessary and sufficient to support the programming of TRM cell fate in tissue-infiltrating T cells. Recent evidence suggests that TCR signals received in infected nonlymphoid tissues additionally contribute to TRM cell formation. Here, we asked how antigen-dependent pathways influence the generation of skin-resident memory T cells that arise from a polyclonal repertoire of cells induced by infection with an antigenically complex virus and recombinant vaccine vector. We found that CD8+ T cells of different specificities underwent antigen-dependent competition in the infected tissue, which shaped the composition of the local pool of TRM cells. This local cross-competition was active for T cells recognizing antigens that are coexpressed by infected cells. In contrast, TRM cell development remained largely undisturbed by the presence of potential competitors when antigens expressed in the same tissue were segregated through infection with antigenically distinct viral quasispecies. Functionally, local cross-competition might serve as a gatekeeping mechanism to regulate access to the resident memory niche and to fine-tune the local repertoire of antiviral TRM cells.