The effect of varying effective index and random deviations of domain boundary on sum frequency generation (SFG) in quasi-phase-matching waveguides are analyzed and analytical expressions of the conversion efficiency are provided for the first time to our knowledge. By simplifying the coupled equations of SFG in waveguide, we provide analytical expressions of the conversion efficiency for the first time. Four models for variations of effective index and random errors of domains are investigated. The results demonstrate that, when effective index varying regularly along the waveguide, the normalized conversion efficiency η ^ of SFG is reduced and the curves of η ^ are no longer sinc 2 function but ripple profiles, which is different from the situation in bulk crystals; with the same magnitude, random period error is of much more significance than random duty cycle error, which is similar with the case in bulk crystals.