The type VI secretion system (T6SS) is a secretion pathway widespread in Gram-negative bacteria that targets toxins in both prokaryotic and eukaryotic cells. Although most T6SSs identified so far are involved in inter-bacterial competition, a few are directly required for full virulence of pathogens. The T6SS comprises 13 core proteins that assemble a large complex structurally and functionally similar to a phage contractile tail structure anchored to the cell envelope by a trans-membrane spanning stator. The central part of this stator, TssM, is a 1129-amino-acid protein anchored in the inner membrane that binds to the TssJ outer membrane lipoprotein. In this study, we have raised camelid antibodies against the purified TssM periplasmic domain. We report the crystal structure of two specific nanobodies that bind to TssM in the nanomolar range. Interestingly, the most potent nanobody, nb25, competes with the TssJ lipoprotein for TssM binding in vitro suggesting that TssJ and the nb25 CDR3 loop share the same TssM binding site or causes a steric hindrance preventing TssM-TssJ complex formation. Indeed, periplasmic production of the nanobodies displacing the TssM-TssJ interaction inhibits the T6SS function in vivo. This study illustrates the power of nanobodies to specifically target and inhibit bacterial secretion systems.