The control over the formation of a bi-component porous network was attained by the self-assembly at a solid-liquid interface by exploiting both primary and secondary non-covalent interactions between melamine and N(3)-alkylated xanthine modules.