Preheat the air fryer: Set to 350°F (175°C) for 5 minutes. Lightly oil or line the basket with a small piece of parchment cut to fit, leaving space for air flow.
Mix dry ingredients: In a large bowl, whisk flour, baking powder, baking soda, salt, and sugar until well combined.
Cut in the butter: Add diced cold butter. Use your fingertips or a pastry cutter to blend until the mixture looks like coarse crumbs with a few pea-size bits.
Add wet ingredients: In a measuring cup, combine buttermilk and egg (if using).
Pour into the flour mixture. Stir with a fork until a shaggy dough forms. It should look slightly sticky, not wet.
Bring it together: Dust a clean surface with flour.
Turn out the dough and gently knead 4–6 times, just until it comes together. Avoid overworking.
Shape the loaf: Form a round mound about 5–6 inches wide and 1.5–2 inches tall. Use a sharp knife to score a deep cross on top, about 1/2 inch deep.
This helps it bake evenly.
Brush and bake: Brush the top lightly with milk or buttermilk for a golden finish. Place the loaf on the parchment in the air fryer basket. Cook at 350°F (175°C) for 22–28 minutes, depending on your air fryer.
Check for doneness: The loaf should be deep golden and sound hollow when tapped on the bottom.
An instant-read thermometer in the center should read around 195–200°F (90–93°C).
Cool briefly: Transfer to a rack and let rest 10–15 minutes before slicing. This helps the crumb set and keeps it from crumbling.
Serve: Slice and enjoy warm with butter, honey, jam, or alongside soup or salad.