© 2021 Elsevier LtdAn energy and battery management systems (EMS/BMS) have a great importance in PV-battery system to increase the system efficiency and battery life. In this study, a prototype battery management system (BMS) has been designed and implemented for grid-connected residential-PV system with lithium-ion battery (LIB). Besides the main function of the all BMS which is to keep the LIBs within the safe-operation condition, by measuring/monitoring and controlling the battery parameters during the charge/discharge cycles, this designed BMS manages also the energy flow between PV system, battery, grid and load. In the designed BMS, there is a measuring unit (to measure current, voltage and temperatures), a control unit (to control the energy flows in the system), balancing circuit (capable of balancing in each of the four modules with 7LIB connected in series), the battery circuit (to fix the batteries well and measure the charge/discharge currents on the battery module). The proposed prototype system includes the designed BMS, 400Wp PV modules, 18650 type lithium-ion batteries (LIB) block with a capacity of 353 Wh, the programmable 300 W electronic DC load for modelling the various load profiles by reducing the real home energy consumption by 1/15, 300 W power supply for supplying the energy from the grid and 24 V light bulbs for the sale of excess energy to the grid. For retired and working household power consumption profiles, various scenarios were created for 24-h power consumption on different days on weekdays/weekends to test the proposed prototype system. These scenarios were uploaded on the electronic load, the operation of the designed battery and energy management system was tested with these experiments by using proposed prototype set-up. The battery management system ensured that the batteries operate in safe working conditions. Due to the energy management function of BMS, when the PV-batteries system is not sufficient, the energy will be taken from the grid; when the PVs charged batteries fully, the excess energy will be sold to the grid. Therefore, the designed prototype system, providing a flexible manner with various load profiles, will be useful tool in the investigation of the optimum conditions for a grid connected PV-battery system designed.