Measurements of shear wave velocity and attenuation as a function of temperature were made in the kilohertz frequency range in sandstones saturated with various liquids. For sandstones partially saturated with glycerol, two attenuation peaks are observed between -80 degrees C and 100 degrees C; they are attributed to viscous shear relaxation and squirt flow. For fully water-saturated Berea sandstone, the attenuation decreases as the crack density increases. The displacement of the squirt peak, caused by the increase of the central aspect ratio of cracks, is at the origin of this decrease.A simple viscoelastic model, based on the model of O'Connell and Budiansky using a Cole-Cole distribution of cracks, is proposed for calculation of the shear modulus of fluid-saturated rocks. This model interprets the experimental data satisfactorily. The data suggest that the shear attenuation and velocity are controlled by the distribution of crack aspect ratios.