A novel dynamic covalent gel has been prepared via the imine bond formation reaction of tetraamine building blocks with luminescent tetraphenylethene tetraaldehyde units. The gel shows high hierarchical porosity (SBET = 512 m(2) g(-1)) and remarkable aggregation-induced emission enhancement, which has been demonstrated to be a selective sensor.