Long solitary waves in incompressible density stratified fluids are described, to the first order in wave amplitude by the Korteweg-de Vries equation. A well-known solution of this equation represents a single solitary wave that has the familiar "sech2" profile and a phase speed that varies linearly with the wave amplitude. In the present paper the modifications of these waves resulting from the compressibility are investigated. Solitary waves are again described by the Korteweg-de Vries equation. Three special cases are discussed and results are compared with the results of incompressible solitary wave theory. This shows that qualitative and quantitative differences may be profound, especially for an isothermal shearless fluid.