which political party had the primary goal of keeping slavery out of the territories

The Republican Party had the primary goal of keeping slavery out of the territories.