The fluid-lubricated bearing, whose maximum temperature is one of the key indicators to determine whether major equipment operates normally, is widely used as the bearing part of major equipment. For temperature prediction, numerical calculation method is commonly used, but not the most accurate method. In this work, a comprehensive test rig for the sliding bearing is used to study the influences of journal linear speed, bearing specific pressure, lubricant viscosity and inlet temperature on bearing temperature. Three machine learning algorithms with different complexity, artificial neural network (ANN), k nearest neighbors (KNN) and random forest (RF) were applied to the test data to predict the maximum temperature. Furthermore, the optimal algorithm was obtained and validated. The results show that the bearing temperature is nonlinearly positively correlated with the four operating parameters. The three algorithms have satisfactory accuracy in the low-to-medium temperature range (20 °C–72 °C), but the accuracy of ANN and RF is significantly reduced in the high temperature region (72 °C–95 °C). It is found that KNN is the optimal algorithm because of its high precision and insensitivity to abnormal data. This study provides a relatively accurate and effective method for quickly and accurately predicting the maximum temperature of fluid-lubricated bearings.