According to the present invention, after forming the buried gate region, the nitride layer spacer is formed on the sidewall of the buried gate region, but the spacer of the active region is etched to leave the spacer in the device isolation region. Provided are a semiconductor device and a method of manufacturing the same, in which shorts do not occur.