Closed-loop supply chains are complex systems as they involve the seamless backward and forward flow of products and information. With the advent of e-commerce and online shopping, there has been a growing interest in product returns and the associated impact on inventory variance and the bullwhip effect. In this paper, a novel four-echelon closed-loop supply chain model is presented, where base-stock replenishment policies are modelled by means of a proportional controller. A stochastic state-space model is implemented, initially to capture the supply chain dynamics while the model is analysed under stationarity conditions with the aid of a covariance matrix. This allows the bullwhip effect to be expressed as a function of replenishment policies and product return rates. Next, an optimisation method is introduced to study the impact of the Internet of Things on inventory variance and the bullwhip effect. The results show that the Internet of Things can reduce costs associated with inventory fluctuations and eliminate the bullwhip effect in closed-loop supply chains.