Rapidly rising energy costs and increasingly rigid environmental standards have led to an emerging trend of addressing the "Energy efficiency" aspect of wireless cellular networks. In cellular networks, Base Stations (BSs) are Power-hungry elements and absorbing them in the smart grid can significantly increase power efficiency. However, this important perspective has been ignored in the energy-efficiency research on cellular networks. In this paper, heterogeneous networks, cognitive radios, and the smart grid are jointly studied to improve energy efficiency. Multiple retailers in the smart grid provide real-time electricity prices to the heterogeneous network, and the Macrocell Base Station (MBS) and Femtocell Base Stations (FBSs) perform energy-efficient power allocation.