We present both low- and high-dispersion spectra for a sample of 19 compact steep-spectrum (CSS) radio galaxies and quasars, as well as a sample of related objects with dominant kiloparsec-scale steep-spectrum radio emission. The basic characteristic of the CSS class is that it contains powerful steep-spectrum radio sources which are confined within the dimensions of the host galaxy. Previous studies suggest that these sources may be good candidates for finding strong interactions between the radio source and the interstellar medium of the host galaxy. Our spectra provide measurements of emission-line flux, flux ratios, equivalent widths, and continuum properties, as well as measurements of the [O III] lambda5007 and Hbeta emission line profile shapes. These data are analyzed in more detail in the second paper in this series, where we compare the optical emission line properties of CSS sources with other classes of active galaxies. As a class, the CSS sources have relatively strong, high equivalent width, high excitation line emission, with broad, structured [O III] lambda5007 profiles. These properties are consistent with the picture of strong interactions between the radio source and the interstellar medium in CSS sources.