It is demonstrated that X-ray beam positions can be extracted from two-dimensional profiles with sub-pixel resolution. Beam-position measurements utilizing a self-designed low-cost two-dimensional detector have been performed at two synchrotron radiation beamlines of the Swiss Light Source. The effective detector pixel size was 4.8 μm and the resolution achieved for the beam position was about 5 nm. At a data rate of 25 frames per second, periodic variations of the beam position could be detected with a frequency resolution below 0.1 Hz. This allowed, for example, the influence of a turbo-pump in the X-ray optics hutch on the beam position to be quantified, and even minute variations related to the electron beam in the storage ring could be detected