In order to accurately predict the energy consumption of traction battery in electric vehicle (EV) and alleviate the mileage anxiety of drivers, a data?driven SOC prediction model for the traction battery in EV is proposed in this paper. Firstly, the composition of energy consumption in EVs is analyzed and the influencing factors of energy consumption are extracted. Then based on the vehicle operation data collected by the CAN bus of an EV with machine learning algorithm adopted, an energy consumption model based on temperature stratification is proposed and the macro data and micro data is fused to reduce errors. Finally, the model is used to verify the SOC data provided by on-board BMS. The results show that the model has a good prediction result, providing a scientific decision support for optimizing the energy control strategy of EVs and alleviating driver’s mileage anxiety.