Recent years have seen revived interest in computer-assisted organic synthesis1,2. The use of reaction-network and neural-network algorithms which can plan multi-step synthetic pathways have revolutionized this field1,3-7, including examples leading to advanced natural products6,7. Such methods typically operate on full, literature-derived “substrate(s)-to-product” reaction rules and cannot be easily extended to the analysis of reaction mechanisms. Here we show that computers equipped with a comprehensive knowledge-base of mechanistic steps augmented by physical-organic chemistry rules, as well as quantum mechanical (QM) and kinetic calculations, can use a reaction-network approach to analyze the mechanisms of some of the most complex organic transformations – namely, cationic rearrangements. Such rearrangements are a cornerstone of organic chemistry textbooks and entail dramatic changes in the molecule’s carbon skeleton8-12. The algorithm we describe and deploy at https://HopCat.allchemy.net/ generates, within minutes, networks of possible mechanistic steps, traces plausible step sequences, and calculates expected product distributions. We validate this algorithm by three sets of experiments whose analysis would likely prove challenging even to highly trained chemists: (i) predicting the outcomes of Tail-to-Head Terpene (THT) cyclizations in which substantially different outcomes are encoded in modular precursors differing in minute structural details; (ii) comparing the outcome of THT cyclizations in solution or in a supramolecular capsule, and (iii) analyzing complex reaction mixtures. Our results support a vision in which computers no longer just manipulate known reaction types1-7 but will help rationalize and discover new, mechanistically complex transformations.