Heat butter over medium heat in a medium size skillet, swirling to coat the bottom. Add walnuts, sugar, cinnamon and cayenne pepper. Stir to evenly coat all nuts.
Continue stirring for 10 minutes as sugar melts. This will help better coat the nuts and prevent burning. Remove from heat and spread nuts out on a piece of parchment. Allow nuts to cool for at least 10 minutes before serving.