If you love Italian gnocchi, this variation with a classic pesto is outstanding. I've been perfecting my potato gnocchi recipe for decades, and it pairs fantastically well with the creamy basil, garlic and parmesan sauce. You can have the potato gnocchi frozen and cook it as needed.

Homemade pasta
Potato gnocchi and basil pesto are a fantastic match.
This recipe makes a creamy sauce that sticks to the little morsels, thanks to the cooking water added. It's the little secret to making this dish the best.
The beauty of homemade gnocchi is that you can double or triple this recipe, make a large batch and freeze it until ready to boil and eat; no need to thaw it.
The pesto can also be made ahead and refrigerated. It can be used for a week or two if stored in an airtight container. Besides the classic one with fresh basil leaves, I also recommend the spinach pesto and the tomato pesto, both twists on the original.
Eat it on the 29th of each month, and it might bring you unexpected money (insert wink emoji). Here in Argentina, it's said that putting a few bills or coins underneath your plate of gnocchi brings economic abundance. While that is debatable, at least you get a big dish of delicious homemade pasta out of the deal.

FAQ
It's not a requirement per se, but in my experience, frozen gnocchi pieces are more easily manageable and don’t get overly gummy or sticky when cooked.
Fresh gnocchi only takes 2-3 minutes to cook from when the water starts to boil. They will let you know they're done when the pieces start floating to the water's surface.
Ingredient Notes
Quantities are listed in the recipe card towards the end of this post. The Ingredients page has more details and lists the brands we use.
- Unseasoned mashed potatoes: Make sure they have enough time to cool them down before beginning. You want them slightly warm, not hot.
- Parmesan cheese: I recommend using fresh cheese, not the packaged stuff. It has a much better flavor in my experience. Asiago or reggianito cheese can also be used.
- Black pepper: freshly ground is my first option.
- Ground nutmeg: It's optional but goes great with the gnocchi.

Make the potato gnocchi
This recipe was taught to me decades ago, but I didn't master it until much later.
One thing to know about homemade gnocchi is that it is a matter of practice. It's cliche, but so true! It took me a while to perfect the method and make soft, pillowy bites.
You have to learn to feel the dough.
If you use too much flour, you will have cute little rocks, and if you add too little, you risk having a big bowl of lumpy mashed potatoes with flour.
Follow the simple instructions in the recipe card, practice, and you'll be making potato gnocchi from scratch that everyone will love in no time.

- Start with slightly warm, unseasoned potato puree. That way, the gnocchi dough won't absorb unnecessary flour.

- Form the shaggy mass into a ball, but don't knead or overwork it. It will not be completely smooth, and that is fine. It will be cut into large pieces that will be rolled into logs.

- You have to form strips with the dough, so cut pieces and roll them like you would to make breadsticks. They will be uneven. Again, don't overwork it.
They have to be soft but stand on their own when you make ropes and cut them. If in doubt, use less flour when forming the log and then roll out the ropes on a lightly floured surface.

- Next comes the fun part, where you cut small pieces and roll or slide them on a fork (or wooden gnocchi board) to create the traditional ridges. You can omit this step, like I did.
It also serves as a trial since you must be able to roll the gnocchi down the fork's tines. If you can't at all, you need more flour. But don't overdo it.
Homemade pesto
Besides this classic one with fresh basil leaves, garlic and parmesan cheese I added in the recipe card, you can use my tomato or spinach pesto. That said, use store-bought pesto if you're in a hurry. Just make sure you follow the instructions for a creamy pesto sauce.

- Place all ingredients except oil in the blender or food processor. I like the immersion blender and a jar; it's easier in my opinion.

- Once you add the oil and cream, it will turn into a smooth and unctuous mixture. So good!
Cooking homemade gnocchi
- Striations: This is the classic look of gnocchi; it has ridges, but you can omit them and cook them like tiny dumplings, and what are they anyway, right?
- Large pot of abundant salted water: it's essential that they have space to cook and float comfortably.
- When are they done? They will float to the surface. Nothing will happen for several minutes, and tiny gnocchi will suddenly start resurfacing. Use a skimmer to remove them as they come up. Don't rush them; stir the water regularly and gently.
- Stir together the pasta and sauce in a large skillet or pot (you can use the one where the gnocchi are boiled) over low heat until it's all coated and mixed. Melting both flavors before serving improves the taste.

Storage
For the gnocchi:
- In the refrigerator: leftover cooked gnocchi (no sauce) should be placed in a well-sealed, airtight container. Stored properly, it will be good for 2-3 days. Stir them with a little oil before refrigerating so they don't stick too much.
- In the freezer: uncooked potato gnocchi freeze beautifully. Place the formed gnocchi pieces on a sheet pan or tray until they are solid, and transfer the frozen pieces to a freezer-safe bag or container to gain space and recover the sheet for other uses. Stored properly, frozen gnocchi will be good for up to 3 months.
- Thawing options: gnocchi is best cooked directly from the freezer. Thawing the gnocchi is not necessary.
- Reheating: Heat already-cooked gnocchi in a saute pan. Heat a little oil over medium-high heat, add the cooked gnocchi, and reheat for about 3-5 minutes or until warmed through. You can also reheat in the microwave on high for 2 minutes or until warmed through thoroughly.
For the pesto:
- Airtight jar: it's my favorite way. Add a thin layer of olive oil on top to prevent oxidation (the basil turning brownish) and keep it as fresh as possible.
- Freezing pesto: This is not my favorite way to keep it, but it works for this creamy one. You might want to add more cream or olive oil and reheat it briefly before serving. The texture usually suffers a little.
Leftovers: Store them in an airtight container in the fridge for up to 5 days. I like to reheat them in the microwave, but you can also use a medium-low oven.

Related recipes you might like:
Let me know
If you made this recipe and loved it, you can comment below and leave a five-star ⭐️ review. Also, if you had issues, let me know so we can troubleshoot together. I appreciate honest feedback and suggestions.
You can also subscribe to our FREE email series 'Baking the Best' and our regular newsletter. Or follow and save my recipes on Pinterest.
As an Amazon Associate, I earn from qualifying purchases. Read my disclosure policy.

Creamy Pesto Potato Gnocchi
Click the stars to Rate this Recipe!
Ingredients
Potato gnocchi:
- 2 pounds Yukon gold or russet potatoes, peeled
- 2 ½ cups all-purpose flour
- 1 egg
- ½ teaspoon salt
- ¼ teaspoon ground black pepper
Pesto sauce:
- ½ cup fresh basil leaves
- 2 garlic cloves
- ⅓ cup walnuts, chopped
- ¼ cup olive oil
- 1 cup heavy cream
- ⅓ cup shredded parmesan cheese
- ½ teaspoon salt
- ¼ teaspoon ground black pepper
Instructions
Make potato gnocchi:
- Wash and peel 2 pounds Yukon gold or russet potatoes. Chop them into large pieces. Boil in water until fork-tender. Drain and mash with a potato masher or potato ricer. Let it cool until warm, covered so the top layer doesn't dry out, about 20 minutes. Don't let them cool completely and don't use cold puree.
- Season mashed potatoes with ½ teaspoon salt and ¼ teaspoon ground black pepper. Add 1 egg and 1 cup of flour. Stir to integrate; don't beat!. Gradually add the remaining flour until you have a dough that is firm but manageable. Use only the necessary flour; don't make it overly stiff.
- Transfer dough to a floured surface. Knead the potato mass until smooth, adding flour to prevent sticking. Again, avoid adding too much flour.
- Divide the dough into four parts. Roll each into a ½ inch thick log or sausage. Cut each rope into bite-sized pieces. Optionally, press each piece against a fork or gnocchi to make the traditional ridges. Dust gnocchi with flour and set aside on a flour-dusted baking sheet. Leave them to dry in a cool place. Repeat for all remaining dough. At this point, I like to freeze them until it's time to cook them.
Make the pesto sauce:
- Combine ½ cup fresh basil leaves, 2 garlic cloves and ⅓ cup walnuts in a food processor. Pulse until finely chopped and somewhat combined, scraping down the sides as needed.
- With the food processor running on low, slowly drizzle in ¼ cup olive oil. Process until smooth and a paste forms, being careful not to over-process.
- Pour 1 cup heavy cream into a large skillet or saucepan that will fit the pesto and gnocchi. Add the pesto base from the food processor to the saucepan with the cream. Stir well to combine.
- Heat over medium-low heat, stirring occasionally, until heated through and slightly thickened (about 5-7 minutes). Do not boil.
- Remove from heat and stir in ⅓ cup shredded parmesan cheese until melted and incorporated. Season with ½ teaspoon salt, or to taste, and ¼ teaspoon ground black pepper, or to taste.
When ready to eat:
- Bring a large pot of salted water to a boil.
- Blend all sauce ingredients until smooth and set the skillet over very low heat after you add the raw gnocchi to the cooking water.
- Cook gnocchi in batches in boiling water (2-3 batches). Gnocchi are done when they float.
- Use a slotted spoon to remove the cooked gnocchi and add them directly to the sauce. Save cooking water and add it in tablespoons to the skillet to loosen up the sauce and make it stick to the pasta.
- Serve gnocchi warm with fresh parmesan cheese and basil leaves.
Rate and review this recipe