Pat the cod fillet dry thoroughly with paper towels to remove excess moisture .This helps the surface set properly during cooking.
Brush the cod lightly on all sides with olive oil, using a pastry brush or clean fingers for an even coating.
Season both sides of the fish with salt and black pepper, if using.
Preheat the air fryer to 400°F (200°C) for about 3 minutes.
Place the cod fillet into the air fryer basket, skin-side down if applicable, leaving space around it for air circulation.
Cook for 8 minutes, checking at the halfway point. Flip the fillet if desired, though flipping is optional.
The cod is done when it looks opaque, flakes easily with a fork, and has lightly set edges.
Carefully remove the fish with tongs and transfer it to a plate. Let it rest for 1 minute before serving.
Serve immediately, optionally with lemon wedges or fresh herbs.