Heat a medium saucepan over medium-high heat. Add 2 Tbsp of the olive oil and sauté 2 grated cloves of garlic, pine nuts, and red pepper flakes until fragrant, 30 to 45 seconds. Fold in the breadcrumbs and cook until they are toasted all over and turn golden brown, 3 to 4 minutes. Fold in the za’atar and ½ tsp ground black pepper. Taste and season with more za’atar and salt. Remove from the heat and transfer to a bowl. Wipe the saucepan clean and return to the stove.
While the breadcrumbs cook, prepare the pasta. Follow the manufacturer’s instructions. Set a large pot of salted boiling water on the stove and cook the spaghetti until it turns al dente. Drain the cooked pasta and transfer to a large bowl.
Heat the remaining 2 Tbsp of olive oil in the same saucepan, add and sauté 2 grated cloves of garlic until fragrant, 30 to 45 seconds. Fold in the preserved lemons and cooked spaghetti.
Place the ricotta, lemon juice, and zest in a medium mixing bowl, add and whip using a hand mixer or food processor. Taste and season with salt and black pepper.
Divide the ricotta and pasta between 4 serving bowls. Top with 2 to 3 generous tablespoons of the breadcrumb mixture and garnish with fresh basil. Drizzle with extra-virgin olive oil, if desired. Serve immediately. Leftovers can be stored in an airtight container for up to 4 days.
