
This pumpkin spinach and walnut spaghetti is a simple, wholesome meal perfect for those midweek evenings when you want something comforting but easy to prepare. Roasted pumpkin brings a natural sweetness that pairs beautifully with the peppery bite of spinach and the crunch of toasted walnuts. If you keep roasted pumpkin or butternut squash in your fridge, you can have this on the table in less than 30 minutes, making it a dependable go to dish.
I first tried this during a busy week when I had leftover roasted pumpkin and it quickly became a family favorite. Now it pops up on the table regularly, especially as the weather cools and those cozy flavors shine.
Ingredients
- Spaghetti: 200 g of spaghetti (glutenfree if needed) for a pasta base that holds the sauce well
- Extra virgin olive oil: 45 ml of extra virgin olive oil for richness and silky texture choose a good quality one for the best flavor
- Garlic: 2 to 3 garlic cloves finely diced, to add aromatic depth fresh is best for that punch
- Butternut squash or pumpkin: 450 g of cubed butternut squash or pumpkin roasted until caramelized for natural sweetness and softness
- Spinach: 100 g of fresh spinach for bright color and earthiness baby leaves are tender and cook quickly
- Chilli flakes: Half to one teaspoon of chilli flakes to introduce a gentle kick adjust to your heat preference
- Lemon: Half a lemon for zest and juice which adds freshness and balances the sweetness of the pumpkin
- Salt and pepper: Salt and freshly ground pepper to season properly
- Walnuts: 30 g of walnuts finely chopped to sprinkle on top for texture and nutty flavor lightly toast if possible
Instructions
- Sear the Pumpkin:
- Coat the cubed pumpkin with one tablespoon of olive oil and lightly salt it. Spread the cubes on a baking tray and roast in a 220 degree Celsius/430 degree Fahrenheit oven. Roast for about 25 to 30 minutes, turning halfway through to caramelize all sides. The pumpkin should be tender and lightly browned, which brings out its natural sweetness and depth.
- Infuse the Oil:
- While the pumpkin roasts, heat two tablespoons of olive oil in a skillet over a medium low heat. Add the diced garlic and gently fry, stirring often to ensure it cooks evenly and does not burn. After about three minutes, sprinkle in the chilli flakes. Cook together for another minute or two so the oil carries the warmth of the chilli and the garlic is fragrant without bitterness.
- Prepare the Pasta:
- Cook the spaghetti according to package instructions but reduce the cooking time by one minute so the pasta is just al dente. This gives the final dish a little bite when combined with the sauce and allows it to finish cooking in the pan.
- Mash and Combine:
- Remove half of the roasted pumpkin cubes and mash them using a fork or potato masher. For a smoother texture, you can pulse them in a food processor or blender. Return both the mashed and whole pumpkin pieces to the pan with garlic and chilli. This creates a sauce that clings well to the pasta.
- Toss with Spinach and Spice:
- Drain the spaghetti and add it directly to the pan with pumpkin. Toss in the washed spinach leaves while still hot so they wilt gently into the mix. Stir everything together to combine all flavors. Taste and adjust seasoning with salt and pepper. Add a squeeze of lemon juice for brightness and more chilli flakes if you like heat. A little extra olive oil can be drizzled at this point if desired.
- Serve and Garnish:
- Serve immediately with a generous sprinkle of chopped walnuts on top. Finish with fresh lemon zest for an added layer of citrus aroma and a pop of color.

I remember the first time I made it when my kids complained about eating "green stuff" but ended up asking for seconds after tasting the walnut crunch paired with the garlicky, vibrant sauce.
Storage Tips
Store any leftovers in an airtight container in the fridge for up to two days. The dish reheats well on the stovetop with a splash of water or olive oil to loosen the sauce.
Ingredient Substitutions
If you can't find butternut squash or pumpkin, kabocha squash or even sweet potatoes work well and keep the sweetness intact. Spinach can be swapped for kale or Swiss chard for a heartier green. Walnuts can be replaced with toasted pecans or almonds.
Serving Suggestions
This pasta pairs wonderfully with a simple green salad and a light white wine. For more protein, serve alongside roasted chicken or pan seared fish.

Quick to make and full of cozy flavors, this pasta is easy to adapt. Leftovers reheat well making it a practical weeknight option.
Common Recipe Questions
- → Can I use butternut squash in place of pumpkin?
Yes, butternut squash works perfectly as it offers a similar texture and sweetness that complements the other ingredients well.
- → How can I make this dish gluten-free?
Use gluten-free spaghetti varieties available in stores to keep the dish suitable for gluten-intolerant diets.
- → What spices enhance the flavors best?
Garlic and chilli flakes bring warmth and depth, while a squeeze of lemon juice brightens the overall flavor.
- → How do I achieve the best caramelisation for the pumpkin?
Roast cubed pumpkin at a high temperature (220ºC) for 25-30 minutes, stirring halfway to ensure even caramelisation.
- → Can I prep the ingredients in advance?
Yes, roasting the pumpkin beforehand and washing the spinach in advance can save time during cooking.
- → What textures should I expect in this dish?
The dish balances creamy mashed pumpkin, tender pasta, wilted spinach, and crunchy walnuts, offering a satisfying mouthfeel.