3 tablespoons olive oil
1 pound sweet potatoes (about 2 medium sweet potatoes), peeled and cut into 3/4-inch cubes
1 medium yellow onion, chopped
3 tablespoons Thai red curry paste
3 garlic cloves, minced (about 1 tablespoon)
1 (1-inch) piece fresh ginger, peeled and grated (about 1 tablespoon)
1 red chile, such as Fresno or serrano, halved, seeds and ribs removed, then minced
1 teaspoon ground turmeric
1 cup red lentils, rinsed
4 cups low-sodium vegetable stock
2 teaspoons kosher salt, plus more to taste
1 (13-ounce) can full-fat coconut milk
1 (4- to 5-ounce) bag baby spinach
½ lime, juiced
Fresh cilantro leaves, for serving
In a Dutch oven or pot, heat 2 tablespoons olive oil over medium-high. Add the sweet potatoes and cook, stirring occasionally, until browned all over, 5 to 7 minutes. Transfer the browned sweet potatoes to a plate and set aside.
Add the remaining 1 tablespoon olive oil to the pot and set the heat to medium-low. Add the onion and cook, stirring occasionally, until translucent, 4 to 6 minutes. Add the curry paste, garlic, ginger, chile and turmeric, and cook until fragrant, about 1 minute.
Add the lentils, stock, salt and browned sweet potatoes to the pot and bring to a boil over high. Lower the heat and simmer, uncovered, stirring occasionally, until the lentils are just tender, 20 to 25 minutes.
Add the coconut milk and simmer, stirring occasionally, until the liquid has reduced and the lentils are creamy and falling apart, 15 to 20 minutes.
Add the spinach and stir until just wilted, 2 to 3 minutes. Off the heat, stir in the lime juice and season with salt to taste.
Divide among shallow bowls and top with cilantro and coconut flakes, if using.