An X-ray detector according to an embodiment includes a scintillator array and a photodiode array. In the scintillator array, a plurality of scintillators are arranged in a first direction and a second direction intersecting the first direction. The photodiode array includes photodiodes each of which is installed for a different one of the scintillators and each of which has an active area configured to convert visible light emitted by the scintillator into an electrical signal. The photodiodes are arranged in such a manner that the widths of the active areas are equal to one another in the first direction.