A magnetic field type mass spectrometer having an ion source, an ion accelerator, a mass separation magnet forming an analyzing part which changes the trajectory of ions by a magnetic field of the mass separation magnet, and a current detector, wherein the mass separation magnet is installed so that ions move along a trajectory which turns several times in the analyzing part, and repelling electrodes are installed at turning points of the ions, whereby ions generated from the ion source are caused to move along a trajectory which turns several times in the analyzing part. Mass separation is carried out along each trajectory, which provides high resolution.