In combination with existing observations and detailed circumstellar models, the detection of hydrogen deuteride emission from the star TW Hydrae implies a circumstellar disk mass of more than 0.05 solar masses, which is enough to form a planetary system like our own. The mass of a protoplanetary disk is a key influence on its likely fate, and a new way of estimating that mass, requiring fewer assumptions than other methods, should aid these studies. For planets to have formed, our Solar System at birth required a minimum disk mass of about 0.01 solar masses within around 100 astronomical units of its centre. This study reports the detection of the fundamental rotational transition of hydrogen deuteride (HD) in the circumstellar disk of the star TW Hydrae. Distribution of this gas mirrors that of molecular hydrogen, and its spectral emission is thought to trace the total mass. Its presence, together with modelling data, implies a disk mass of more than 0.05 solar masses, sufficient to form a planetary system like our own. At 3–10 million years old, TW Hydrae is considered old for a protoplanetary disk, yet it is still young enough to develop into a planetary system. From the masses of the planets orbiting the Sun, and the abundance of elements relative to hydrogen, it is estimated that when the Solar System formed, the circumstellar disk must have had a minimum mass of around 0.01 solar masses within about 100 astronomical units of the star1,2,3,4. (One astronomical unit is the Earth–Sun distance.) The main constituent of the disk, gaseous molecular hydrogen, does not efficiently emit radiation from the disk mass reservoir5, and so the most common measure of the disk mass is dust thermal emission and lines of gaseous carbon monoxide6. Carbon monoxide emission generally indicates properties of the disk surface, and the conversion from dust emission to gas mass requires knowledge of the grain properties and the gas-to-dust mass ratio, which probably differ from their interstellar values7,8. As a result, mass estimates vary by orders of magnitude, as exemplified by the relatively old (3–10 million years) star TW Hydrae9,10, for which the range is 0.0005–0.06 solar masses11,12,13,14. Here we report the detection of the fundamental rotational transition of hydrogen deuteride from the direction of TW Hydrae. Hydrogen deuteride is a good tracer of disk gas because it follows the distribution of molecular hydrogen and its emission is sensitive to the total mass. The detection of hydrogen deuteride, combined with existing observations and detailed models, implies a disk mass of more than 0.05 solar masses, which is enough to form a planetary system like our own.