Preheat the oven to 350°F (175°C).
In a large bowl, combine mashed sweet potatoes, sugar, eggs, salt, 4 tbsp melted butter, milk, and vanilla. Mix until smooth.
Pour the sweet potato mixture into a greased 9x13-inch baking dish.
In a separate bowl, combine 1/3 cup melted butter, brown sugar, flour, and chopped pecans.
Sprinkle the pecan topping evenly over the sweet potato mixture.
Bake for 30–35 minutes or until the topping is golden and crispy.
Let cool for a few minutes before serving.