Recent advances in renewable energy generation and the Internet of things (IoT) has urged energy management to enter the era of the Internet of energy (IoE). The IoE adopts a huge number of distributed energy-generating facilities, distributed energy storage facilities, and IoT technologies to implement energy sharing, promote utilization of electrical grids, and maintain safety of electrical grids. Rapid economic and social development makes energy shortage tend to be increasingly serious. Most cases of energy shortage occur during the peak energy load, and hence the previous works focused on shifting peak load to address energy shortage. However, few of these works took the IoE framework into account. Consequently, this work aims to consider the IoE framework to investigate the peak load shifting problem in which end-users in the energy market can adopt their respective energy storage facilities to charge and discharge energy to minimize the total operating costs. In such a problem setting, each end-user can not only be a demander, but also be a supplier in the energy market, so that operating costs are concerned; the energies from both conventional electrical grids and distributed renewable energy sources can be stored in energy storage facilities; real-time price of energy will be applied adequately to affect energy distribution of supply and demand. Simulation results of a case study show that the proposed model can obtain the optimal result and achieve peak load shifting.