The ionization energy increases going right in a period because protons are being added to the atom but no electron are being added to the inner energy level, which increases the effective nuclear charge. Therefore, the valence electrons are held more tightly and the atom shrinks in size, so, difficulty to remove the electrons increases.