This paper studies a residential PV-ESS energy system scheduling problem with electricity purchase cost, storage degradation cost and surplus PV generated cost [2]. This problem can be viewed as an online optimization problem in time t ∈ [1, T ] with switching costs between decision at t − 1 and t. We reformulate the problem into a single variable problem with s = (s 1 , ..., s T) T , which denotes the storage energy content. We then propose a new algorithm, named Average Receding Horizon Control (ARHC) to solve the PV-ESS energy system scheduling problem. ARHC is an online control algorithm exploiting the prediction information with W-steps look-ahead. We proved an upper bound on the dynamic regret for ARHC of order O(nT /W), where n is the dimension of decision space. This bound can be converted to a competitive ratio of order 1 + O(1/W). This result overcomes the drawback of the classical algorithm Receding Horizon Control (RHC), which has been proved [11] that it may perform bad even with large look ahead W. We also provide a lower bound for ARHC of order O(nT /W 2) on the dynamic regret. ARHC is then used to study a real world case in residential PV-ESS energy system scheduling.