A magnetic sensor for detecting
magnetism in two-axial directions or three-axial directions is constituted of a substrate, a
silicon oxide film that is formed on the substrate so as to form the planar surface and slopes, a plurality of magnetoresistive elements, each of which is formed by laminating a free layer, a conductive layer, and a pin layer on the substrate, a plurality of lead films that are formed to connect the magnetoresistive elements in series, a CVD
oxide film for covering the magnetoresistive elements, and a non-magnetic film that is formed between the magnetoresistive elements and the CVD
oxide film so as to cover the periphery of the free layer with respect to each magnetoresistive element. Thus, it is possible for the magnetic sensor to include the magnetoresistive elements having superior
hysteresis characteristics.