First principles calculation is conducted to systematically investigate the effects of alloying elements (Mo, Re, Os, Ta, Ti, and V) on phase stability, stacking fault energy, ductility, and restoring force of W. It is found that the addition of Mo, Re and Os would decrease the generalized stacking fault energy (GSFE) of W and increase the ductility of W, while the alloying elements of Ti, Ta, and V could enhance its GSFE and reduce its ductility. The different effects of alloying elements would be mainly attributed to the intrinsic interaction between W and the alloying element, i.e., the repulsive interaction of W-Mo, W-Re, and W-Os with positive heats of formation would increase the interlayer distance of W and facilitate its slip, whereas the attractive interaction of W-Ti, W-Ta, and W-V with negative heats of formation would reduce the interlayer distance of W and impede the slip. The derived results are in good agreement with available observations in the literature, and could provide a deep understanding of the effects of alloying elements on various properties of W.