Preheat your oven to 350°F (175°C). Line a 9×13-inch baking pan with parchment paper, leaving an overhang on two sides as handles for lifting. Lightly spray the parchment and exposed pan sides with nonstick spray.
In a medium bowl, whisk together the melted butter, 1/2 cup granulated sugar, vanilla, and 1/2 teaspoon fine sea salt until glossy and well combined. Add 2 cups flour and stir until no dry pockets remain, then fold in 1 1/2 cups unsweetened shredded coconut until evenly distributed. The dough will be thick and slightly sticky.
1 cup unsalted butter, 1/2 cup granulated sugar, 1 teaspoon pure vanilla extract, 1/2 teaspoon fine sea salt, 2 cups all-purpose flour, 1 1/2 cups unsweetened shredded coconut
Transfer the crust mixture to the prepared pan. Use clean hands or the back of a measuring cup to press it into an even layer, pressing firmly into the corners so the base holds together. Bake for 15–18 minutes, or until the edges are lightly golden and the surface looks set.
While the crust bakes, prepare the filling. In a large bowl, whisk the eggs until well combined and slightly frothy. Add 1 3/4 cups granulated sugar and whisk until thick and pale, about 30–45 seconds. Sprinkle in 1/4 cup flour, cornstarch, and 1/4 teaspoon fine sea salt, whisking gently until no dry streaks remain. Slowly whisk in the fresh lime juice, then the lime zest and coconut milk, mixing until smooth.
4 large eggs, 1 3/4 cups granulated sugar, 1/4 cup all-purpose flour, 2 tablespoons cornstarch, 1/4 teaspoon fine sea salt, 3/4 cup fresh lime juice, 1 tablespoon lime zest, 1/4 cup canned coconut milk
When the crust comes out of the oven, give the lime filling a quick stir and carefully pour it over the hot crust. Return the pan to the oven and bake for 20–25 minutes, until the center looks just set and no longer sloshes when you gently shake the pan. A slight jiggle, like soft gel, is fine.
Set the pan on a wire rack and let the bars cool to room temperature, about 1–1 1/2 hours. Once cooled, transfer the pan to the refrigerator and chill for another 1–2 hours, or until very cold, so the filling sets firmly and slices cleanly.
If using, sprinkle toasted shredded coconut evenly over the chilled bars and gently press it into the surface. Use the parchment overhang to lift the slab out of the pan onto a cutting board. Dust with powdered sugar, then use a sharp knife to cut into 24 smaller bars or 18 larger squares, wiping the knife with a warm, damp cloth between cuts for the cleanest edges.
1/2-3/4 cup shredded coconut, powdered sugar