PurposeThe rapid development of e-commerce has brought not only great convenience to people but a great challenge to online stores. Phenomenon such as out of stock and slow sales has been common in recent years. These issues can be managed only when the occurrence of the sales volume is predicted in advance, and sufficient warnings can be executed in time. Thus, keeping in mind the importance of the sales prediction system, the purpose of this paper is to propose an effective sales prediction model and make digital marketing strategies with the machine learning model.Design/methodology/approachBased on the consumer purchasing behavior decision theory, we discuss the factors affecting product sales, including external factors, consumer perception, consumer potential purchase behavior and consumer traffic. Then we propose a sales prediction model, M-GNA-XGBOOST, using the time-series prediction that ensures the effective prediction of sales about each product in a short time on online stores based on the sales data in the previous term or month or year. The proposed M-GNA-XGBOOST model serves as an adaptive prediction model, for which the instant factors and the sales data of the previous period are the input, and the optimal computation is based on the proposed methodology. The adaptive prediction using the proposed model is developed based on the LSTM (Long Short-Term Memory), GAN (Generative Adversarial Networks) and XGBOOST (eXtreme Gradient Boosting). The model inherits the advantages among the algorithms with better accuracy and forecasts the sales of each product in the store with instant data characteristics for the first time.FindingsThe analysis using Jingdong dataset proves the effectiveness of the proposed prediction method. The effectiveness of the proposed method is enhanced and the accuracy that instant data as input is found to be better compared with the model that lagged data as input. The root means squared error and mean absolute error of the proposed model are found to be around 11.9 and 8.23. According to the sales prediction of each product, the resource can be arranged in advance, and the marketing strategy of product positioning, product display optimization, inventory management and product promotion is designed for online stores.Originality/valueThe paper proposes and implements a new model, M-GNA-XGBOOST, to predict sales of each product for online stores. Our work provides reference and enlightenment for the establishment of accurate sales-based digital marketing strategies for online stores.