The emergence of perovskite (typically CH3NH3PbI3) solar cells revolutionized the field not only because of their rapidly increased efficiency, but also flexibility in material growth and architecture. The superior performance of the perovskite solar cell suggested that perovskite materials possess intrinsically unique properties. In this talk, I will present our recent theoretical investigations into the structural, electrical, and optical properties of halide perovskite materials, especially CH3NH3PbI3, in relation to their applications in solar cells. (i) the optical transitions of CH3NH3PbI3 is direct p-to-p transition, which combines the advantage of the first- and second-generation solar cell materials, responsible for the strong optical absorption [1]; (ii) different from common p-type thin-film solar cell absorber, it exhibits flexible conductivity from good p-type, intrinsic to good n-type depending on the growth conditions; (iii) dominating intrinsic defects create only shallow defect levels, which partially explain the long carrier electron-hole diffusion length and high open-circuit voltage[2]; (iv) molecular dynamics simulations show that the structure of pristine CH3NH3PbI3 is much more distorted than the inorganic archetypal thin-film semiconductor CdTe. However, the structure disorders from both thermal fluctuation and grain boundaries (GBs) introduce no deep defect states within the band gaps, therefore, the polycrystalline show single-crystal-like properties; (v) although GBs introduce no gap states, they could act as hole trap state and increase the carrier effective mass. Cl and O can spontaneously segregate into GBs and passivate those defect levels and deactivate the trap state [3]. The unusual physical properties of perovskite are attributed to the unique electronic structures of halide perovskite: the strong coupling between cation lone-pair s orbital and anion p orbitals and the large atomic size of constitute cation atoms. The correlation of experimental observations and the verification of our theoretical results, which may further guide experimental research will also be discussed [4]. [1] W.-J. Yin, T. Shi and Y. Yan, Adv. Mater. 26, 4653 (2014). [2] W.-J. Yin, T. Shi and Y. Yan, Appl. Phys. Lett. 104, 063903 (2014). [3] W.-J. Yin, H. Y. Chen, T. Shi, S.-H. Wei, and Y. Yan, Adv. Elect. Mater. 1, 1400044 (2015). [4] W.-J. Yin, J.-H. Yang, J. Kang, Y. Yan and S.-H. Wei, J. Mater. Chem. A 3, 8926 (2015).