Prep the oven and pan: Heat the oven to 350°F (175°C).
Line a 12-cup muffin tin with paper liners or lightly grease with butter or coconut oil.
Mix dry ingredients: In a large bowl, whisk 2 cups almond flour, 2 tablespoons coconut flour, 2 teaspoons baking powder, 1 1/2 teaspoons cinnamon, 1/2 teaspoon apple pie spice, and 1/4 teaspoon salt.
Stir wet ingredients: In another bowl, whisk 2/3 cup granulated keto sweetener, 1/2 cup melted butter, 3 large eggs, 1/2 cup sour cream, and 2 teaspoons vanilla until smooth.
Combine gently: Pour the wet mixture into the dry ingredients. Stir just until combined. The batter will be thick; that’s normal.
Prep the apple: Finely dice about 1/2 cup of apple (from half a small apple).
Toss with 1 teaspoon lemon juice. Pat dry to remove excess moisture.
Fold in extras: Fold the diced apple into the batter. Add 1/4 cup chopped nuts if using.
Don’t overmix.
Portion the batter: Divide evenly among the muffin cups, filling each about 3/4 full. Smooth the tops slightly with a spoon.
Optional cinnamon topping: Mix 1 teaspoon granulated sweetener with 1/2 teaspoon cinnamon and sprinkle over the muffins for a light crust.
Bake: Bake for 18–22 minutes, until the centers are set and a toothpick comes out clean or with a few moist crumbs.
Cool: Let the muffins cool in the pan for 5 minutes, then transfer to a rack to cool completely. They firm up as they cool.