Bodø lies within the auroral zone, the band of latitudes where the northern lights appear most regularly. The viewing season runs from late September through March — you need darkness, which the midnight sun season eliminates. The best conditions are clear, cold nights with low geomagnetic activity — counterintuitively, extremely active nights can produce displays that are too diffuse and rapidly moving to see clearly. The Norwegian meteorological service (yr.no) includes aurora forecasts; the Space Weather Prediction Center in the US publishes the Kp index, which is the number to watch.
You do not need to leave the city. The waterfront faces north and the horizon is open; Keiservarden gives a 360-degree view. For darker skies, drive 20–30 minutes out of town on the E6 or the Rv17. Saltstraumen in particular is excellent: no artificial light, the sounds of the current, and a northern sky that fills with colour on a good night. Tours are available from several operators, but they do not guarantee a sighting — no one can. Dress extremely warmly; standing still in the cold for hours requires more layers than you think.