This study investigates the compressive mechanical behavior of Sn3.0Ag0.5Cu (SAC305) lead-free solder under varying temperature and strain rate conditions. Compression tests were performed using an electronic universal testing machine across four distinct temperatures (20 °C, 60 °C, 100 °C, and 140 °C) and five different strain rates( \(1\times {10}^{-3}{s}^{-1}\) , \(5\times {10}^{-4}{s}^{-1}\) , \(2\times {10}^{-4}{s}^{-1}\) , \(8\times {10}^{-5}{s}^{-1}\) , \(5\times {10}^{-5}{s}^{-1}\) ) Stress–strain curve of SAC305 obtained by constant temperature compression test. The Anand viscoplastic model was applied to fit the experimental data, analyzing temperature and strain rate effects on the mechanical properties of material. The results demonstrate that SAC305 exhibits strong dependence on both temperature and strain rate. Specifically, yield stress decreases with an increase in temperature, while it increases with higher strain rates. Notably, the temperature effect is more pronounced than the strain rate effect. Moreover, the Anand viscoplastic model, when fitted to the experimental data, shows excellent agreement with the observed stress–strain behavior, confirming its suitability for predicting the mechanical response of SAC305 solder under diverse thermal and strain rate conditions. These findings provide a theoretical foundation for subsequent simulation studies on the thermal-vibration coupling performance of SAC305 lead-free solder joints.