Design and constructing hierarchical architecture nanostructure is very effective to achieve good electrochemical performance for lithium-ion batteries (LIBs) and sodium-ion batteries (SIBs). Herein, uniform hierarchical Fe7S8 nanostructures coated by thin carbon layer (Fe7S8/C) have been prepared by a facile Polyvinylpyrrolidone (PVP) assisting hydrothermal method and heat treatment. PVP is acting dual function as both a surfactant for self-assembly of the secondary structure, and also providing porous carbon layers equably coating on Fe7S8 nanostructures after annealing process. Benefiting from the well-designed structure, a high reversible capacity of 751mAhg−1 over 100 cycles at 100mAg−1 is delivered for LIBs, and it also manifests superior sodium ion storage properties with a capacity of 497mAhg−1 after 100 cycles at 100mAg−1. The remarkable electrochemical performance of the Fe7S8/C composite implies the great potential as high capacity anode for next generation energy storage.