while leaving the shells attached, depending on the recipe.
Using a small, sharp paring knife, make a shallow incision along the back of the shrimp. Look for the thin, dark digestive tract just beneath the surface.
Lift it gently with the tip of the knife or use a deveining tool to pull it out. If necessary, rinse away any visible residue without spreading raw seafood juices around the kitchen.
Repeat the process for the remaining shrimp.
For dishes that call for shell-on shrimp, you can often remove the digestive tract