We carry out ab initio density functional theory calculations to investigate the fundamental mechanical properties of stacking faults in 3C-SiC, including the effect of stress and doping atoms (substitution of C by N or Si). Stress induced by stacking fault (SF) formation is quantitatively evaluated. Extrinsic SFs containing double and triple SiC layers are found to be slightly more stable than the single-layer extrinsic SF, supporting experimental observation. Effect of tensile or compressive stress on SF energies is found to be marginal. Neglecting the effect of local strain induced by doping, N doping around an SF obviously increase the SF formation energy, while SFs seem to be easily formed in Si-rich SiC.