Electronic and crystal structures of CsPbIBr2 perovskite compounds doped with copper (Cu) or tin (Sn) were investigated. From the band calculations, an energy gap of CsPbIBr2 was reduced by the Cu or Sn doping, and optimized crystal structures of CsCuIBr2 were compared with the fabricated crystals. Energy gaps of Cu- or Sn-doped CsPbIBr2 were measured by optical absorption and external quantum efficiencies of the cells, and compared with the calculations. Addition of a small amount of Cu or Sn to the CsPbIBr2 increased the short-circuit current density of the fabricated solar cells, which agree with the expected results from the calculated band structures and partial density of states.