Porous anodic alumina photonic crystals with a photonic stop-band placed in the mid-infrared spectral region represent a promising approach for increasing of gas sensors sensitivity. An onion-like layered distribution of anionic impurities is a hallmark of porous anodic alumina, and its presence is generally considered to demarcate the boundary between transparent and opaque ranges in the infrared spectral region. Here, we study the effect of annealing in the temperature range of 450–1 100 °C on the structural stability and optical properties in photonic crystals based on porous anodic alumina fabricated by pulse anodization in oxalic acid. Pulse sequences were selected in a way to obtain photonic crystals of different periodic structures with a photonic stop-band located in visible and mid-infrared spectral regions. The first photonic crystal was composed of layers with gradually changing porosity, whereas the second photonic crystal consisted of a sequentially repeated double-layer unit with an abrupt change in porosity. We investigated the response of alumina with rationally designed porosities and different arrangements of porous layers for high-temperature treatment. The microstructure (scanning electron microscopy), phase composition (x-ray diffraction), and optical properties (optical spectroscopy)were analysed to track possible changes after annealing. Both photonic crystals demonstrated an excellent structural stability after 24 hour annealing up to 950 °C. At the same time, the evaporation of the anionic impurities from porous anodic alumina walls caused a shift of the photonic stop-band towards the shorter wavelengths. Furthermore, the annealing at 1 100 °C induced a high transparency (up to 90%) of alumina in mid-infrared spectral region. It was shown thus that properly selected electrochemical and annealing conditions enable the fabrication of porous photonic crystals with the high transparency spanning the spectral range up to around 10 µm.