Coconut cream pie squares are a make-ahead dessert for potlucks, picnics, and holiday tables. They have a buttery shortbread crust, a rich coconut custard filling, and a whipped topping, all in a bar that you can cut into neat squares. Serve them chilled with coffee or tea, or as a lighter finish after a heavy meal.
Ingredients
- For the crust: 1 1/2 cups (190 g) all-purpose flour, 1/2 cup (100 g) granulated sugar, 1/2 cup (115 g) cold unsalted butter, cut into small pieces, 1/4 teaspoon salt
- For the filling: 1 cup (200 g) granulated sugar, 1/2 cup (60 g) cornstarch, 1/2 teaspoon salt, 4 large egg yolks, 2 cups (480 ml) whole milk, 1 cup (240 ml) canned coconut milk (full-fat), 2 teaspoons vanilla extract, 1 1/2 cups (120 g) sweetened shredded coconut, divided
- For the topping: 1 1/2 cups (360 ml) heavy cream, 1/4 cup (30 g) powdered sugar, 1 teaspoon vanilla extract, 1/2 cup (40 g) toasted coconut flakes (optional)
Instructions
- Preheat the oven to 350°F (175°C). Line a 9×9-inch (23×23 cm) baking pan with parchment paper, leaving overhang on two sides.
- Make the crust: In a medium bowl, whisk together flour, sugar, and salt. Cut in the cold butter using a pastry blender or your fingers until the mixture resembles coarse crumbs. Press evenly into the bottom of the prepared pan. Bake for 18-20 minutes, until lightly golden. Let cool completely on a wire rack.
- Make the filling: In a medium saucepan, whisk together sugar, cornstarch, and salt. In a separate bowl, whisk the egg yolks. Gradually whisk in the milk and coconut milk until smooth. Pour the liquid into the saucepan and whisk to combine.
- Cook over medium heat, stirring constantly with a whisk, until the mixture thickens and comes to a gentle boil, about 8-10 minutes. Boil for 1 minute, then remove from heat. Stir in the vanilla and 1 cup (80 g) of the shredded coconut.
- Pour the hot filling over the cooled crust. Smooth the top. Press a piece of plastic wrap directly onto the surface to prevent a skin from forming. Refrigerate until completely chilled and set, at least 3 hours or up to overnight.
- Make the topping: In a chilled bowl, beat the heavy cream, powdered sugar, and vanilla with an electric mixer on medium-high speed until stiff peaks form, about 2-3 minutes. Spread over the chilled filling.
- Toast the remaining 1/2 cup (40 g) shredded coconut in a dry skillet over medium heat, stirring frequently, until golden, about 2-3 minutes. Let cool, then sprinkle over the topping.
- Chill for at least 30 minutes before slicing. Use the parchment overhang to lift the whole slab onto a cutting board. Cut into 16 squares with a sharp knife, wiping the blade between cuts.
Substitutions and Swaps
Use these swaps when you need them, and know what changes:
- Dairy-free: Use a plant-based butter substitute in the crust (choose one that is solid and cold) and replace the whole milk with unsweetened oat milk or almond milk. Use a dairy-free whipped topping instead of the whipped cream. The filling will be slightly less creamy but still set.
- Light coconut milk: You can use light coconut milk, but the filling will be less rich and may be slightly thinner. Reduce the milk by 1/4 cup (60 ml) to compensate.
- Unsweetened coconut: If you use unsweetened shredded coconut, increase the sugar in the filling by 2 tablespoons (25 g) to keep the same sweetness.
- Graham cracker crust: Replace the shortbread crust with 1 1/2 cups (180 g) graham cracker crumbs mixed with 1/3 cup (75 g) melted butter. Press into the pan and bake at 350°F (175°C) for 8-10 minutes. The crust will be less firm and more crumbly.
Equipment That Matters
Use a 9×9-inch (23×23 cm) metal or glass baking pan. A metal pan gives a crisper crust; glass may require a few extra minutes of baking. Parchment paper overhang is essential for lifting the bars out cleanly. A whisk is important for a lump-free custard; a silicone spatula helps scrape the bottom of the pan while cooking. If you don’t have a pastry blender, use two knives or your fingers to cut the butter into the flour.
Storage and Make-Ahead
Store the squares in an airtight container in the refrigerator for up to 4 days. The crust may soften slightly over time. To freeze, wrap the un-cut slab (without the whipped topping) tightly in plastic wrap and then foil; freeze for up to 2 months. Thaw overnight in the refrigerator, then add the whipped topping and coconut before serving. Do not freeze the assembled bars with whipped cream, as it will weep and lose texture. Keep the bars refrigerated until serving; they should not sit at room temperature for more than 2 hours.
Why the Filling Sets
The cornstarch and egg yolks work together to thicken the custard. Cornstarch needs to reach a boil to activate, so the 1-minute boil is crucial. The filling will be soft when warm but will firm up as it chills. If your filling is lumpy, strain it through a fine-mesh sieve before pouring over the crust. If it doesn’t set after 3 hours, it may not have boiled long enough; return it to the saucepan, bring to a boil for 1 minute, and chill again.
Related
- Lemon Break Game Recipe: Easy Citrus Squares
- Chocolate Mousse Using Coconut Cream
- Pumpkin Bread Using Coconut Pie Filling
Safe minimum internal temperatures follow USDA FSIS; raw-fish guidance follows the U.S. FDA. See our food safety notes.
Spotted an error? Tell us and we will correct it (corrections policy).