This paper aims at designing an online energy management strategy (EMS) for a multi-stack fuel cell hybrid electric vehicle (FCHEV) to enhance the fuel economy as well as the fuel cell stacks (FCSs) lifetime. In this respect, a two-layer strategy is proposed to share the power among four FCSs and a battery pack. The first layer (local to each FCS) is held solely responsible for constantly determining the real maximum power and efficiency of each stack since the operating conditions variation and ageing noticeably influence stacks' performance. This layer is composed of a FCS semi-empirical model and a Kalman filter. The utilized filter updates the FCS model parameters to compensate for the FCSs' performance drifts. The second layer (global management) is held accountable for splitting the power among components. This layer uses two inputs per each FCS, updated maximum power and efficiency, as well as the battery state of charge (SOC) and powertrain demanded power to perform the power sharing. The proposed EMS, called adaptive state machine strategy, employs the first two inputs to sort the FCSs out and the other inputs to do the power allocation. The ultimate results of the suggested strategy are compared with two commonly used power sharing methods, namely Daisy Chain and Equal Distribution. The results of the suggested EMS indicate promising improvement in the overall performance of the system. The performance validation is conducted on a developed test bench by means of hardware-in-the-loop (HIL) technique.