The invention discloses a method of simultaneously extracting caffeic acid and ferulic acid in cimicifuga rhizome. The method comprises the following steps: firstly, weighing according to certain ratio and dissolving ferulic acid, caffeic acid and zinc acetate in an acetonitrile-dimethyl sulfoxide mixed solution, vibrating, adding a functional monomer 4-VP, sufficiently vibrating, then adding a mixed cross-linking agent EDMA-DVB and an initiator AIBN, sufficiently mixing the raw materials, transferring the raw materials into a round-bottom flask, degassing, feeding argon, and sealing the bottle; secondly, laying the bottle into a 60 DEG C thermostat water bath, performing crushing after the completion of a polymerization reaction, and performing sieving, settling, filtering, eluting and vacuum drying; thirdly, loading an obtained molecularly imprinted polymer into a solid-phase extraction tube, and performing washing and eluting after the loading. The method adopts a metal ion coordination imprinting technology, takes a binary compound metal ion complex as template molecules, synthesizes the molecularly imprinted polymer with high selective recognition property, and has high practical value by simultaneously extracting the caffeic acid and the ferulic acid in the cimicifuga rhizome through the molecularly imprinted polymer.