Objectives To estimate (1) the number of current and former injecting drug users (IDU) infected with human immunodeficiency virus (HIV) alive in Edinburgh, and (2) the total number of current injectors in the city. Methods The number of infected IDU was estimated using a local register of HIV infections with correction for incompleteness of the register. The number of injectors was estimated by two independent methods, one based on the HIV register, the other by log-linear modelling of four lists of IDU interviewed in a city-wide survey, and/or attending drug treatment agencies and family doctors because of drug use. Main outcome measures Estimates for the period 1992-1994 of number of IDU infected with HIV, total number of IDU, and prevalence of injecting. Results The HIV register indicated that 371 infected drug users who had ever injected were alive and resident in Edinburgh. In all, 95% of infected survey respondents appeared in the register, leading to a corrected estimate of 472 infected ever injectors. From this the number of IDU currently injecting (i.e. in the previous 6 months) was estimated to be 1770 (95% CI: 1340-2240), and the prevalence of injecting as 8.0 (95% CI: 4.8-10.8) per 1000 Edinburgh residents aged 15-59 years. Log-linear modelling gave an estimate of 2070 (95% CI:1360-2800) current injectors. Conclusions The number of HIV-infected IDU in Edinburgh was estimated to be twice that in the larger nearby city of Glasgow, where a higher proportion of young adults currently injected drugs. Knowledge of the high prevalence of HIV in Edinburgh IDU (19.3%), the prescribing of oral substitutes, and counselling by doctors and drug workers are perceived reasons for the reduction in the prevalence of injecting which has occurred in Edinburgh in recent years. Such measures need to be continued to encourage further reduction of injecting.