Regression is often used in analysis of spatial data to obtain predictive relationships between variables. The assumption that the errors from the regression model are statistically independent will often not be plausible, due to spatial dependence in the sources of error. This is a problem for the regression analysis in that the resulting estimate of the standard deviation of the errors from the model is biased (downwards) which invalidates confidence limits on predictions made with the model, and which could lead to a false conclusion that the regression is statistically significant. While the estimates of the regression coefficient(s) are not necessarily biased they are not minimum-variance estimates when the errors are correlated. It is shown how the maximum likelihood method of estimating the regression model (ML) might be used to overcome this problem. It is proposed that standard variogram functions may be used to model the spatial dependence of the errors from the regression. In simulation studies it is shown that the method avoids bias in the estimation of the standard deviation of the regression error from a systematic sample (unless the spatial interval over which the errors are correlated is of similar order to the dimensions of the systematic sample grid). The precision of the ML estimate of the error is poorer than achieved from a random sample, but this can be improved to some extent by constraining the parameters of the variogram function. The ML procedure is demonstrated in the analysis of some remote sensor data to predict organic matter content of the top soil within an arable field. The data on top soil had been collected on a systematic grid. Analysis of the residuals from an ordinary least-squares regression indicated an appropriate variogram function to model the spatial dependence of the errors. Confidence limits for predictions using the regression were calculated from the ML estimate of the error.