A novel and efficient method, namely Solid-state fermentation combined with ionic liquid pretreatment and ultrasonic-assisted extraction (SSFIPU), was successfully established for the extraction of anthocyanins (ACs) from Schisandra chinensis residue samples. Additionally, an enzymatic combined with ionic liquid pretreatment and ultrasonic-assisted extraction technique (EIPU) was effectively developed to extract Schisandrin A (SDA) and Schizandrin B (SDB) from the residue after AC extraction. A comprehensive examination was conducted on ten crucial parameters of SSFIPU and eight essential parameters of EIPU. The Box-Behnken design was employed to optimize the influencing factors and precisely predict the optimal extraction conditions. The optimized conditions were as follows: For SSFIPU, with 4 mol/L [BMIM]BF