Collaborative cloud-edge-end computing is a promising solution to support computation-intensive and latency-sensitive tasks by utilizing rich computing resources of cloud datacenters and low access delay of mobile edge computing (MEC) servers. Compared with traditional cloud computing and MEC, the cloud-edge environment has a stronger heterogeneity of servers and networks, resulting in significant differences between servers in the computation speed and access delay. However, few studies on cloud-edge-end task offloading focused on the characteristic of 5G heterogeneous networks in the cloud-edge environment. In this paper, we study the task offloading problem for collaborative cloud-edge-end computing in MEC-enabled small cell networks with low-cost distributed wireless backhaul. We aim to minimize the energy consumption of all user devices (UDs) via jointly optimizing the offloading decision, UDs’ transmission power, and the allocation of spectrum and computation resources. To solve the non-convex problem, we decouple the original problem into three subproblems, and design an efficient method with solving these three subproblems iteratively to obtain a high-quality solution. The simulation results indicate that our proposed method can lead to significant reduction in the energy consumption of all UDs compared with other conventional methods.