Both analytical and numerical works show that magnetic reconnection must occur in hot accretion flows . This process will effectively heat and accelerate electrons . In this paper we use the numerical hybrid simulation of magnetic reconnection plus test-electron method to investigate the electron acceleration and heating due to magnetic reconnection in hot accretion flows . We consider fiducial values of density , temperature , and magnetic parameter \beta _ { e } ( defined as the ratio of the electron pressure to the magnetic pressure ) of the accretion flow as n _ { 0 } \sim 10 ^ { 6 } { cm ^ { -3 } } , T _ { e } ^ { 0 } \sim 2 \times 10 ^ { 9 } { K } , and \beta _ { e } = 1 . We find that electrons are heated to a higher temperature T _ { e } = 5 \times 10 ^ { 9 } K , and a fraction \eta \sim 8 \% of electrons are accelerated into a broken power-law distribution , dN ( \gamma ) \propto \gamma ^ { - p } , with p \approx 1.5 and 4 below and above \sim 1 MeV , respectively . We also investigate the effect of varying \beta and n _ { 0 } . We find that when \beta _ { e } is smaller or n _ { 0 } is larger , i.e , the magnetic field is stronger , T _ { e } , \eta , and p all become larger .