Backfire

what,would cause a 1999 jeep cherokee 4 liter inline 6 to backfire every now and then.

Under what conditions does this occur? Accelerating? When you lift your foot from the accelerator? Other?