The paper puts forward a fractal dimension algorithm that fuses mid-wave and long-wave infrared images and detects targets. Usually, the targets in infrared images are man-made, and their fractal dimensions are different from that of their natural background. In the fractal dimension algorithm, the source images are first decomposed by wavelet transformation. Then in the wavelet transformation domain, fractal dimensions are calculated and fusion rules that merge corresponding sub images of two matching source images are set up, and new sub images are created. Finally, the image is reconstructed by inverse wavelet transformation and a fused image is obtained. The fusion results have shown that the contrast between the targets and their background has changed significantly, and the targets can be easily detected by applying a contrast threshold. The experimental results have shown that the method using fractal dimension to fuse dualband infrared images and detect targets is superior to the one using mid-wave or longwave infrared images to detect targets alone.