A detection device comprising: an upper detection electrode; a lower detection electrode disposed under the upper detection electrode in an overlapping manner; a proximity state detection unit configured to detect a proximity state of a detection target relative to a detection surface based on a change in at least one of electrostatic capacitances of the upper detection electrode and the lower detection electrode, wherein the detection surface is disposed over the upper detection electrode; and a switching unit configured to perform switching between a first state in which the upper detection electrode and the lower detection electrode are insulated from each other and a second state in which the upper detection electrode and the lower detection electrode are short-circuited to each other, wherein the detection device has a first detection mode and a second detection mode, wherein, in the first detection mode, the switching unit is configured to switch the upper detection electrode and the lower detection electrode to the first state, and the proximity state detection unit is configured to detect a proximity state of the detection target based on a change in an electrostatic capacitance of the upper detection electrode, and wherein, in the second detection mode, the switching unit is configured to switch the upper detection electrode and the lower detection electrode to the second state, and the proximity state detection unit is configured to detect a proximity state of the detection target based on a change in an electrostatic capacitance of the upper detection electrode and the lower detection electrode, characterised in that the detection device further comprises a shield electrode disposed under the lower detection electrode in an overlapping manner, the switching unit is configured to cause the lower detection electrode to function as a portion of the shield electrode by short-circuiting the shield electrode and the lower detection electrode in the first detection mode. an upper detection electrode; a lower detection electrode disposed under the upper detection electrode in an overlapping manner; a proximity state detection unit configured to detect a proximity state of a detection target relative to a detection surface based on a change in at least one of electrostatic capacitances of the upper detection electrode and the lower detection electrode, wherein the detection surface is disposed over the upper detection electrode; and a switching unit configured to perform switching between a first state in which the upper detection electrode and the lower detection electrode are insulated from each other and a second state in which the upper detection electrode and the lower detection electrode are short-circuited to each other, wherein the detection device has a first detection mode and a second detection mode, wherein, in the first detection mode, the switching unit is configured to switch the upper detection electrode and the lower detection electrode to the first state, and the proximity state detection unit is configured to detect a proximity state of the detection target based on a change in an electrostatic capacitance of the upper detection electrode, and the switching unit is configured to switch the upper detection electrode and the lower detection electrode to the first state, and the proximity state detection unit is configured to detect a proximity state of the detection target based on a change in an electrostatic capacitance of the upper detection electrode, and wherein, in the second detection mode, the switching unit is configured to switch the upper detection electrode and the lower detection electrode to the second state, and the proximity state detection unit is configured to detect a proximity state of the detection target based on a change in an electrostatic capacitance of the upper detection electrode and the lower detection electrode, the switching unit is configured to switch the upper detection electrode and the lower detection electrode to the second state, and the proximity state detection unit is configured to detect a proximity state of the detection target based on a change in an electrostatic capacitance of the upper detection electrode and the lower detection electrode, characterised in that the detection device further comprises a shield electrode disposed under the lower detection electrode in an overlapping manner, the switching unit is configured to cause the lower detection electrode to function as a portion of the shield electrode by short-circuiting the shield electrode and the lower detection electrode in the first detection mode.