Dvanajstletni Max Connor živi sam z mamo Alice, oče ga je zapustil že pred desetimi leti. Nekega dne najde škatlo, v kateri je že dolga leta ujet duhec po imenu Kazaam v podobi znanega košarkarja Shaquillea O'Neala. Ko Max Kazaama spusti na prostost, se Kazaam, ki ima nadnaravno moč, ponudi, da mu izpolni tri želje. Sčasoma se med Maxom in Kazaamom splete prijateljstvo, ki ga spremlja cel kup nepozabnih dogodivščin.
Being a lone young boy in the 'hood" is dangerous and unpleasant. This is what Max experiences when he fools a gang of local toughs who cornered him at school. The gang finds out that the key he gave them is of no value in committing a robbery, and they chase him through the streets of his neighborhood, bent on revenge. He tries to escape by slipping into the open door of an old warehouse, but they follow him there, too. While running from them through aisles filled with all kinds of stuff, he bumps into an old boom box. By doing that, he manages to release Kazaam, a genie who has been held captive for thousands of years. In order to stay free, Kazaam must give Max three wishes.