Analysis of heavy metals in soils, sand, and sewage sludge samples has been studied by means of time-resolved optical emission spectrometry from laser-induced plasma. The instrumental setup has been developed as a fast screening detector for future application as an on-line and in situ method. Several experimental parameters had to be optimized. Various factors affecting the detection limits and the quality of the analysis have been investigated. These include aerosol production, crater formation, size effects, timing effects, laser intensities, and humidity. In order to improve reproducibility of elemental analysis, a special data analysis program has been developed. It consists of a data analysis program and of the principal component regression calibration technique, which utilizes many spectral lines for each element. A special renormalization algorithm has been tested for internal calibration. The computer program provides good calibration plots and detection limits in the 10 µg/g range, which are usually below the ecological requirements.