Jelly is a soft semisolid containing gelatine (or gelatin). Gelatine is processed from the protein collagen found in skin and bones, so we wouldn’t advise eating jelly if you’re a vegetarian. The molecules in gelatine are intertwined in a triple helix. As they are mixed with hot water their bonds break, unravelling and becoming long stretchy wiggly lines. As the water cools down, the helices start to reform and cross-linking occurs. This creates supermolecules that are so long they span across the whole jelly in a three-dimensional web, and water gets trapped in the spaces giving jelly its wobble.
Dwaine Anthony Clarke, Science Museum