The building sector is responsible for a significant amount of energy consumption and greenhouse gas (GHG) emissions. Thus, the monitoring, control and optimization of energy consumption in buildings will play a critical role in the coming years in improving energy efficiency in the building sector and in reducing greenhouse gas emissions. However, while there are a significant number of studies on how to make buildings smarter and manage energy through smart devices, there is a need for more research on integrating buildings with legacy equipment and systems. It is therefore vital to define mechanisms to improve the use of energy efficiency in existing buildings. This study proposes a new architecture (PHOENIX architecture) for integrating legacy building systems into scalable energy management systems with focus also on user comfort in the concept of interoperability layers. This interoperable and intelligent architecture relies on Artificial Intelligence/Machine Learning (AI/ML) and Internet of Things (IoT) technologies to increase building efficiency, grid flexibility and occupant well-being. To validate the architecture and demonstrate the impact and replication potential of the proposed solution, five demonstration pilots have been utilized across Europe. As a result, by implementing the proposed architecture in the pilot sites, 30 apartments and four commercial buildings with more than 400 devices have been integrated into the architecture and have been communicating successfully. In addition, six Trials were performed in a commercial building and five key performance indicators (KPIs) were measured in order to evaluate the robust operation of the architecture. Work is still ongoing for the trials and the KPIs’ analysis after the implementation of PHOENIX architecture at the rest of the pilot sites.