The gravitational-wave observatories LIGO and VIRGO can be sensitive to phase transitions in the early universe that happened at temperatures around 10^8 GeV. This energy scale is well motivated by the axion solution to the strong CP problem of the standard model. I first review the production of gravitational waves during phase transitions in the early universe as well as the strong CP problem and its solution by means of the axion. I then show that the phase transition of the scalar field that gives rise to the axion can lead to gravitational waves which may be detectable at LIGO and VIRGO.