With the rapid growth of connected devices, new issues emerge, which will be addressed by boosting capacity, improving energy efficiency, spectrum usage, and cost, besides offering improved scalability to handle the growing number of linked devices. This can be achieved by introducing new technologies to the traditional Internet of Things (IoT) networks. Visible light communication (VLC) is a promising technology that enables bidirectional transmission over the visible light spectrum achieving many benefits, including ultra-high data rate, ultra-low latency, high spectral efficiency, and ultra-high reliability. Light Fidelity (LiFi) is a form of VLC that represents an efficient solution for many IoT applications and use cases, including indoor and outdoor applications. Distributed edge computing is another technology that can assist communications in IoT networks and enable the dense deployment of IoT devices. To this end, this work considers designing a general framework for IoT networks using LiFi and a distributed edge computing scheme. It aims to enable dense deployment, increase reliability and availability, and reduce the communication latency of IoT networks. To meet the demands, the proposed architecture makes use of MEC and fog computing. For dense deployment situations, a proof-of-concept of the created model is presented. The LiFi-integrated fog-MEC model is tested in a variety of conditions, and the findings show that the model is efficient. © 2022 by the authors. Licensee MDPI, Basel, Switzerland.