The majority of structural efforts addressing RNA's catalytic function have focused on natural ribozymes, which catalyze phosphodiester transfer reactions. By contrast, little is known about how RNA catalyzes other types of chemical reactions. We report here the crystal structures of a ribozyme that catalyzes enantioselective carbon-carbon bond formation by the Diels-Alder reaction in the unbound state and in complex with a reaction product. The RNA adopts a lambda-shaped nested pseudoknot architecture whose preformed hydrophobic pocket is precisely complementary in shape to the reaction product. RNA folding and product binding are dictated by extensive stacking and hydrogen bonding, whereas stereoselection is governed by the shape of the catalytic pocket. Catalysis is apparently achieved by a combination of proximity, complementarity and electronic effects. We observe structural parallels in the independently evolved catalytic pocket architectures for ribozyme- and antibody-catalyzed Diels-Alder carbon-carbon bond-forming reactions.