Spaghetti with green beans is a popular and traditional vegetarian pasta dish in Southern Italy.
It is perfect for warm days when meals need to be light and easily prepared. Although best made when beans and tomatoes are in season, you can make this dish all year round. Great way to get kids to eat their greens!

History
Green beans, also known as string beans or snap beans, have been a staple food for thousands of years. This member of the Phaseolus Vulgaris species originated in South America. From there, native tribes took it to Central and North America. However, here in Europe, green beans didn't arrive until Christopher Columbus brought them over in 1493!
Apparently, Greece, Italy and Turkey were already cultivating green beans in the 17th century. Today, Italy, Spain and Belgium are the most important European green bean growers!
In Puglia, this pasta with green beans usually includes marzotica ricotta or a strong ricotta called ‘scuanta’, both of which are produced in Puglia. Some people use cacioricotta, which is what I used.
This ricotta cheese is made in a number of different regions, Campania, Calabria, Basilicata, Puglia and Lazio, and is more widely available. It has quite a delicate and delicious taste and is made from sheep or goat milk, a mix of both or from even cow or buffalo milk. You can also use pecorino, ricotta salata or even Parmigiano.
Ingredients
Fresh green beans are widely available throughout Italy in spring and summer (from May to the end of September). Italians mostly serve them in a salad, as a vegetable side dish or, like this recipe, with pasta.
In Italy, this green bean pasta is called spaghetti con fagiolini alla Pugliese, meaning spaghetti with green beans Puglia style. So, as you may imagine, this is a recipe from Puglia, Southern Italy.
- Pasta: While spaghetti is the traditional choice, use any long pasta type you like, such as vermicelli or spaghetti alla chitarra.
- Fresh Green Beans: If fresh ones aren't available, frozen green beans are a great substitute and don't require pre-cooking.
- Ripe Fresh Tomatoes: Juicy and flavorful, they bring a natural sweetness to the sauce. Canned diced tomatoes are a good substitute when fresh ones aren't available.
- Tomato Passata (also known as Tomato Puree or Sieved Tomatoes): This ingredient provides a smooth, rich base to the sauce.
- Garlic Cloves and Red Onion: These aromatics lay the flavorful foundation. For a milder flavor, shallots can be used instead of red onion.
- Red Chili Pepper (Peperoncino): This optional ingredient adds a spicy kick. Use it to adjust the heat level to your liking. Peperoncino is a staple in Southern Italian cooking, bringing authentic heat to the dish.
- Extra Virgin Olive Oil: A must for sautéing, it enhances the overall flavor. Opt for a high-quality olive oil for the best taste.
- Cacioricotta or Pecorino Cheese: These add depth and richness. Parmigiano Reggiano, Grana Padano, or a vegetarian Parmesan are excellent alternatives if you can't find them. Vegans will need to omit the cheese or use a vegan cheese.
Expert Tips
Cooking Green Beans: To ensure the green beans maintain their vibrant color and crisp texture, only cook them very partially. This stops them from being overly mushy after being simmered in the tomato sauce.
Pasta Perfection: Cook the pasta until it’s just al dente to ensure it doesn't become overly soft. It will continue to cook slightly when mixed with the tomato sauce.
Pasta Water: Reserve a cup of pasta cooking water before draining the pasta. If the sauce is too thick after mixing in the pasta and cheese, mix in a few tablespoons of pasta water.
Step by Step Instructions
1) Heat olive oil in a large frying pan or skillet. Add the garlic clove, sliced onion, and whole red chili pepper. Sauté until the onion begins to soften. Then incorporate the quartered tomatoes, cooking until they start to soften.
2) In a large pot of boiling salted water, partially cook the green beans for a few minutes. Then drain and add them to the skillet with the onions and tomatoes. Continue cooking for 5 minutes.
3) Mix in the tomato passata and simmer for 10-15 minutes. Season with salt and black pepper as needed.
4) When the sauce is almost ready, cook the pasta in plenty of boiling salted water according to the instructions on the packet.
5) Remove the garlic clove and red chili pepper from the sauce. Drain the pasta and add it to the green beans and tomato sauce.
6) Stir in a generous amount of grated cacioricotta or pecorino cheese. Optionally, add a handful of chopped fresh parsley or basil.
7) Serve with more grated cacioricotta or pecorino sprinkled on top.
Storage and Leftovers
Storing for Freshness: Keep any leftover pasta with green beans in an airtight container in the refrigerator. It will stay fresh and tasty for up to 3 days.
Reheating: The easiest way to reheat this dish is in the microwave. Simply place the desired amount in a microwave-safe dish, cover it, and heat for a few minutes, stirring halfway through to ensure even heating.
Creative Leftover Idea: If you're feeling creative, repurpose your leftovers into a new meal. Surprisingly, to some, this recipe makes an excellent pasta frittata.
- Start by frying the mixed spaghetti and green beans in olive oil or butter in a skillet over medium heat.
- Cook until the pasta begins to crisp slightly, then pour over beaten eggs mixed with grated cheese, ensuring the egg mixture spreads evenly through the pasta and beans.
- Since this frittata can be tricky to flip, brown the top under the grill.
FAQs
This recipe is vegetarian if you use a vegetarian cheese. Italian pecorino and Parmigiano aren't vegetarian because they make them using animal rennet. I'm not sure about the types of hard ricotta I mentioned but fresh ricotta is vegetarian, so aged ricotta should be too. Check the label.
Italians eat fagiolini alla Pugliese without pasta as a side dish too. You can use this recipe the same way. Just reduce the amount of passata and serve the sauce without pasta!
Yes, you can prepare this dish in advance. Cook everything except the pasta, which you can boil just before serving. Combine the freshly cooked pasta with the pre-made sauce and serve.
More recipes you may like:
- Assassin's spaghetti from Puglia
- Easy gorgonzola pasta with olives
- Spaghetti al limone with ricotta and basil
- Pasta with tomato sauce allo scarpariello
- Walnut sauce pasta
- Spaghetti alla Chitarra recipe
- Spaghetti frittata
If you make this recipe I’d love to hear how it turns out and if you liked it. Please leave a comment here on the blog or on The Pasta Project Facebook page. Looking forward to hearing from you.
Buon appetito!
This recipe was first published in 2017. It has been updated with new photos and text.
Pin for Later:
If you are interested in learning how to make homemade pasta and different types of gnocchi, check out my shop page for some great video online courses from my friends in Rome! Nothing beats learning to make pasta from Italians! Plus while you’re there why not order a copy of one of my pasta recipe cookbooks or checkout some recommended pasta making tools? All great prezzies for pasta lovers!
Amy Liu Dong says
.
Shashi at SavorySpin says
This was perfect for a quick lunch today - thank you!
Debbie says
This Spaghetti with green beans is a perfect example of sometimes the simple dishes are the best. My husband and I loved this . That red chili pepper really added punch of flavor.
Jamie says
My family loved this for dinner last night! The green beans were perfectly cooked and the sauce was fantastic. Thank you!
Katie Crenshaw says
I needed an inspiration for my meatless Mondays. I tried this recipe and really loved how it turned out. The flavors went so well together and it was very filling. I will be making again.
Sean says
This recipe was a new one for me to try and I absolutely loved it!
Bernice says
I certainly would never have thought that this would be a traditional dish! I love how great food travels all over the world and really appreciate that you take the time to talk about the history of a dish in your posts.
Natalie says
Making a pasta meal is the only way to sneak veggies to my kids, lol. They love it, we all to, thanks!
Ann says
I have never made a dish like this before, but it sounds delicious! Love the idea of adding green beans to the spaghetti!
Kathryn says
This green bean pasta is so delicious and I love the flavor of green beans with tomato sauce! Such a perfect dinner, thank you for sharing!
Gloria says
I will just about add anything to pasta. We love green beans. This sounds like dinner tonight. Easy and delicious.
Gabriela says
What a gorgeous recipe! So simple and so satisfying! I used ricotta salata and it turned up wonderful.
Thank you!