A three-dimensional code for the simulation of streamers is introduced. The code is based on a fluid model for oxygen-nitrogen mixtures that includes drift, diffusion and attachement of electrons and creation of new charge carriers through impact ionization and photo-ionization. The electric field created by the space charges is solved self-consistently. The code assumes that the streamer geometry is not far from an axisymmetric configuration and it is therefore possible to apply a relatively coarse discretization in the angular coordinate. The other two coordinates are represented in adaptively refined grids, allowing a fine resolution of the space-charge layer. In order to take advantage of multiprocessor machines, a pseudo-spectral metho...