Unprecedented self-sorting of three-dimensional purely organic cages driven by dynamic covalent bonds is described. Four different cages were first synthesized by condensation of two triamines and two dialdehydes separately. When a mixture of all the components was allowed to react, only two cages were formed, which suggests a high-fidelity self-recognition. The issue of the preference of one triamine