Astronomers measure the amount of light a star gives off in different colours. As a result of Wien's displacement law, hot stars give off more blue light than red; cool stars give off more red light than blue. Coloured filters are used to measure different wavelengths of light from stars. The magnitude of the star is measured first through a standardized B-band ("blue") filter. Then the star's magnitude is measured through a V-band ("visible", peaking in green) filter. The value of V is subtracted from B to get the B-V colour index.
As a star gets cooler and therefore more red, the B-V colour index increases, since smaller magnitudes correspond to brighter light. Hot stars have a small B-V and cool stars have a large B-V. Hotter stars therefore appear to the left on the Hertzsprung-Russell diagram and cooler stars appear on the right.