Prep your pans and oven. Heat the oven to 350°F (175°C). Line two baking sheets with parchment paper. This keeps the cakes from sticking and helps them bake evenly.
Whisk the dry ingredients. In a bowl, whisk 2 cups flour, 1 teaspoon baking powder, 1/2 teaspoon baking soda, and 1/2 teaspoon kosher salt. Set aside.
Cream the butter and sugar. In a large bowl, beat 1/2 cup unsalted butter with 3/4 cup granulated sugar until light and fluffy, about 2–3 minutes. Add 2 large eggs, one at a time, mixing well after each.
Add lemon and vanilla. Mix in 1 tablespoon lemon zest, 2 tablespoons fresh lemon juice, and 1 teaspoon vanilla extract. The mixture may look slightly curdled—totally fine.
Alternate dry ingredients and buttermilk. Add the dry mixture in two additions, alternating with 2/3 cup buttermilk. Start and end with dry. Mix just until combined. The batter should be thick but scoopable.
Scoop the cakes. Use a 1 1/2-tablespoon cookie scoop to drop mounds onto the prepared sheets, spacing about 2 inches apart. Aim for 24–28 rounds total.
Bake until set. Bake 9–11 minutes, rotating pans halfway. The tops should be set and spring back when gently touched, with barely any browning. Cool on the sheet for 5 minutes, then transfer to a rack to cool completely.
Make the raspberry filling. In a small saucepan, cook 1 cup raspberries over medium heat, stirring and mashing, until juicy and slightly thickened, 4–6 minutes. Press through a fine sieve to remove seeds. Cool completely.
Whip the cream cheese frosting. Beat 6 ounces softened cream cheese and 4 tablespoons softened butter until smooth. Add 2–2 1/2 cups powdered sugar, a pinch of salt, and the cooled raspberry puree, a spoonful at a time, until the frosting is creamy and spreadable. If needed, add 1–2 teaspoons heavy cream to loosen or more powdered sugar to thicken.
Match and fill. Pair the cooled cakes by size. Pipe or spread about 1 1/2 tablespoons filling onto the flat side of one cake. Top with its partner and gently twist to set. If you like, roll the edges in pastel sprinkles.
Set and serve. Chill the assembled whoopie pies for 20–30 minutes to firm up the filling. Serve slightly cool or at room temperature.