A fuel cell system comprising: a fuel cell including an anode gas flow channel and a cathode gas flow channel, the fuel cell generating electricity from a hydrogen-containing anode gas supplied to the anode gas flow channel and an oxygen-containing cathode gas supplied to the cathode gas flow channel; an anode off-gas emission path through which an anode off-gas emitted from the anode gas flow channel of the fuel cell flows; and a cathode off-gas emission path through which a cathode off-gas emitted from the cathode gas flow channel of the fuel cell flows; a purge valve that is provided in the anode off-gas emission path between the fuel cell and a junction, the anode off-gas emission path being connected to the cathode off-gas emission path at the junction; an anode gas supply path through which the anode gas that is supplied to the anode gas flow channel flows; an anode gas supplier provided in the anode gas supply path for supplying the anode gas to the anode gas supply path; a cathode gas supply path through which the cathode gas that is supplied to the cathode gas flow channel of the fuel cell flows; a cathode gas supplier provided in the cathode gas supply path for supplying the cathode gas to the cathode gas supply path; and a controller, characterized in that the controller is configured to control the anode gas supplier to stop supplying the anode gas to the anode gas supply path and control the cathode gas supplier to stop supplying the cathode gas to the cathode gas supply path, thereby stopping generation of electricity by the fuel cell, and after the generation of the electricity by the fuel cell is stopped, the controller is configured to open the purge valve and control the anode gas supplier to supply the anode gas to the anode gas supply path, thereby performing a gas purging in which at least a part of the cathode off-gas emission path is purged with a hydrogen-containing gas having passed through the junction, and the hydrogen-containing gas contains at least either the anode gas or the anode off-gas. a fuel cell including an anode gas flow channel and a cathode gas flow channel, the fuel cell generating electricity from a hydrogen-containing anode gas supplied to the anode gas flow channel and an oxygen-containing cathode gas supplied to the cathode gas flow channel; an anode off-gas emission path through which an anode off-gas emitted from the anode gas flow channel of the fuel cell flows; and a cathode off-gas emission path through which a cathode off-gas emitted from the cathode gas flow channel of the fuel cell flows; a purge valve that is provided in the anode off-gas emission path between the fuel cell and a junction, the anode off-gas emission path being connected to the cathode off-gas emission path at the junction; an anode gas supply path through which the anode gas that is supplied to the anode gas flow channel flows; an anode gas supplier provided in the anode gas supply path for supplying the anode gas to the anode gas supply path; a cathode gas supply path through which the cathode gas that is supplied to the cathode gas flow channel of the fuel cell flows; a cathode gas supplier provided in the cathode gas supply path for supplying the cathode gas to the cathode gas supply path; and a controller, characterized in that the controller is configured to control the anode gas supplier to stop supplying the anode gas to the anode gas supply path and control the cathode gas supplier to stop supplying the cathode gas to the cathode gas supply path, thereby stopping generation of electricity by the fuel cell, and after the generation of the electricity by the fuel cell is stopped, the controller is configured to open the purge valve and control the anode gas supplier to supply the anode gas to the anode gas supply path, thereby performing a gas purging in which at least a part of the cathode off-gas emission path is purged with a hydrogen-containing gas having passed through the junction, and the hydrogen-containing gas contains at least either the anode gas or the anode off-gas.