The piperidine ring in the title compound, C24H25NO3, adopts an envelope conformation with the N atom being the flap atom, and each C=C double bond exhibits an E conformation. In the crystal, C-H⋯O hydrogen bonds link the mol-ecules, forming supramolecular layers that stack along the a axis.