Polytypes of ordered defect compound CuIn5Se8 were constructed based on chalcopyrite and CuAu-like CuInSe2. First principles calculation was used to perform structural optimization and calculate the total energy. Total energy calculation shows that P4 symmetry polytype is slightly stable than P222 symmetry polytype. After structural optimization, P4 and P222 symmetry polytypes show small differences in lattice parameters and electronic properties. The calculated band gap of CuIn5Se8 polytypes is 0.30(+0.01) eV higher than that of CuInSe2. The neglect of P222 symmetry polytype is attributed to the imperceptible differences between P4 and P222 symmetry polytypes.