We describe the construction and operation of an x-ray beam size monitor (xBSM), a device measuring e + and e − beam sizes in the CESR-TA storage ring using synchrotron radiation. The device can measure vertical beam sizes of 10 − 100 µm on a turn-by-turn, bunch-by-bunch basis at e ± beam energies of ∼ 2 GeV. At such beam energies the xBSM images x-rays of ≈1-10 keV (λ ≈ 0.1 − 1 nm) that emerge from a hard-bend magnet through a single-or multiple-slit (coded aperture) optical element onto an array of 32 InGaAs photodiodes with 50 µm pitch. Beamlines and detectors are entirely in-vacuum, enabling single-shot beam size measurement down to below 0.1 mA (2.5 × 10 9 particles) per bunch and inter-bunch spacing of as little as 4 ns. At E b = 2.1 GeV, systematic precision of ∼ 1 µm is achieved for a beam size of ∼ 12 µm; this is expected to scale as ∝ 1/σ b and ∝ 1/E b . Achieving this precision requires comprehensive alignment and calibration of the detector, optical elements, and x-ray beam. Data from the xBSM have been used to extract characteristics of beam oscillations on long and short timescales, and to make detailed studies of low-emittance tuning, intra-beam scattering, electron cloud effects, and multi-bunch instabilities.