Preheat the oven: Preheat your oven to 350°F (175°C). Line an 8×8-inch baking pan with parchment paper, leaving some overhang for easy removal.
Combine the ingredients: In a large bowl, mix the well-drained crushed pineapple, shredded coconut, and sweetened condensed milk until evenly combined.
Transfer to the pan: Spread the mixture evenly into the prepared baking pan. Press it down firmly with the back of a spoon or spatula.
Bake: Bake for 25–30 minutes, or until the edges are lightly golden and the center is set.
Cool completely: Remove from the oven and allow the bars to cool completely in the pan.
Cut and serve: Lift the bars out using the parchment paper, then cut into 12 squares or bars.