Patent attributes
A magnetic sensor used to detect detection substances in samples includes a substrate having a first surface and a second surface, which is opposite to the first surface, a magnetoresistance effect element, which is provided on the first surface and in which the resistance of the magnetoresistance effect element changes in accordance with an input magnetic field, and a protective layer that covers the magnetoresistance effect element. The magnetoresistance effect element is configured in a line shape extending in a first direction on the first surface, and has a first region that is positioned at the outer periphery in a plan view, and a second region that is surrounded by the first region. The height of a top surface of the protective layer on the first region is greater than the height of a top surface of the protective layer on the second region.