Heat 1 cup of milk in a medium saucepan over medium heat. When the milk is boiling, remove the saucepan from the heat.
In a medium bowl, combine the sugar, cornstarch, and salt. Slowly whisk in the remaining cup of milk, a little at a time, to avoid clumps. Whisk in the egg.
Gradually whisk the sugar mixture into the milk, stirring constantly.
Return to medium-low heat and cook, whisking constantly, until the pudding comes to a simmer and is thick and creamy, 5 to 7 minutes.
Remove from the heat and whisk in the butter and vanilla until smooth.
Stir in the peanut butter.
Divide the pudding among 4-6 half cup ramekins. Cover with plastic wrap and refrigerate until fully set,about 2 hours.