In recommendation algorithms, data sparsity and cold start problems are inevitable. To solve such problems, researchers apply auxiliary information to recommendation algorithms, mine users' historical records to obtain more potential information, and then improve recommendation performance. In this paper, ST_RippleNet, a model that combines knowledge graphs with deep learning, is proposed. This model starts by building the required knowledge graph. Then, the potential interest of users is mined through the knowledge graph, which stimulates the spread of users' preferences on the set of knowledge entities. In preference propagation, we use a triple multi-layer attention mechanism to obtain triple information through the knowledge graph and use the user preference distribution for candidate items formed by users' historical click information to predict the final click probability. Using ST_RippleNet model can better obtain triple information in knowledge graph and mine more useful information. In the ST_RippleNet model, the music data set is added to the movie and book data set; additionally, an improved loss function is used in the model, which is optimized by the RMSProp optimizer. Finally, the tanh function is added to predict the click probability to improve recommendation performance. Compared with current mainstream recommendation methods, ST_RippleNet achieves very good performance in terms of the area under the curve (AUC) and accuracy (ACC) and substantially improves movie, book and music recommendations.