Prep ingredients: Preheat oven to 450°F with a rack in the center. Bring a large pot of salted water to a boil. Finely grate lemon zest, then squeeze 2 tablespoons juice into a separate bowl. Peel and finely chop 4 large garlic cloves. Pick and roughly chop parsley leaves. Trim stem ends from zucchini and cut lengthwise into quarters.
Roast zucchini: On a rimmed baking sheet, toss zucchini with 1 tablespoon oil; season with 1⁄4 teaspoon salt and several grinds of pepper. Roast zucchini, shaking sheet halfway through, until tender and well- browned, 15–20 minutes. Immediately toss with half of the lemon zest.
Cook spaghetti: Add spaghetti to boiling water and cook until al dente, 10–12 minutes. Reserve 1⁄2 cup pasta water, then drain spaghetti.
Cook shrimp: Meanwhile, heat 2 tablespoons oil in a large skillet over medium-high. Pat shrimp dry, then season all over with 1⁄4 teaspoon salt and a few grinds pepper. When oil is hot, add shrimp and cook, stirring, until opaque and just cooked through, 1–2 minutes. Transfer with a slotted spoon to a large bowl, leaving oil in the skillet.
Make lemon-butter sauce: Add garlic to same skillet and cook until fragrant, about 1 minute. Add 2 tablespoons butter and stir until melted. Remove skillet from heat, stir in lemon juice, remaining lemon zest, and 1⁄2 teaspoon each salt and pepper. Transfer sauce to bowl with shrimp.
Finish & serve: Add spaghetti to bowl with shrimp along with half of the chopped parsley; toss well to combine, adding a few tablespoons of reserved pasta water if necessary to loosen sauce. Season to taste with salt and pepper and garnish with remaining parsley. Serve with zucchini alongside.