Roles of internal climate variabilities regulating global and ocean temperature changes is a hot but complex issue of scientific concern, influencing the comprehensive policy-making in response to global and regional warming. In this study, the time series of monthly global and ocean mean surface temperature (GST and OST, respectively) since 1866 is successfully reconstructed via natural and anthropogenic forcing factors and internal climate variability by using a Multi-Layer Perceptron (MLP) neural network technique. The MLP demonstrates prominent monthly GST and OST reconstruction skills on both interannual and annual time scales. Most of the warming in GST and OST since 1866 is found to be attributable to anthropogenic forcing, while the multidecadal and interannual GST and OST variations are considerably dominated by Atlantic Multidecadal Oscillation (AMO). Internal climate variabilities like Interdecadal Pacific Oscillation (IPO) can amplify the GST and OST changes and explain the global warming slowdown since 1998. Southern Oscillation Index (SOI) performs a similar role as IPO but to a lesser extent. Changes in OST caused by solar forcing are more considerable than those in GST. Moreover, the ‘biased warmth’ during the Second World War is successfully reconstructed in MLP. AMO and IPO can explain most annual and even sub-annual temperature variations during this period, offering an explanation for the existence of this abnormal warm period other than that it was entirely caused by instrumental errors. The generally high accuracy of reconstructions on interannual and annual time scales can enhance the ability to monitor the prompt feedback of specific external radiative forcings and internal variabilities to changes in climate.