The smart electrical grid represents a significant advancement in generating, distributing, and consuming electricity. This sophisticated system integrates modern technology and communication tools to enhance energy management efficiency and improve demand costuming within the power network. In this paper, optimal operation of the electrical network with energy management and demand response program (DRP) is implemented. The implementation of the optimal operation is done via multi-stage and multi-objective functions modeling. The DRP modeling is done in first stage to optimal management of consumption in demand side. In second stage, operating cost, emission, power losses and voltage profile are optimized as multi-objective functions modeling with attention to optimal management of consumption in demand side. The solving optimal operation of the electrical network is carried out by using elephant herding optimization (EHO). This problem is implemented on 33-bus test system with hybrid energy resources. Finally, DRP leads to reducing costs, emissions and losses and improving voltage profile in proposed electrical network. Hence, operation costs, emission, power losses, and voltage deviation with the participation of DRP are minimized by 39.15%, 9.94%, 33.35%, and 30.73%, respectively. On the other side, voltage stability is enhanced by 3.66% without considering DRP.