Preheat the oven to 350°F (175°C). Grease a 9x5-inch loaf pan or line with parchment paper.
Mash the ripe bananas in a large bowl. Use overripe bananas for the sweetest, moistest bread.
Drain and chop the pineapple if using fresh. If canned, drain it thoroughly.
Sift the dry ingredients: Flour, baking soda, and a pinch of salt in a separate bowl.
Mix butter and sugar in a bowl until smooth and fluffy.
Add eggs and vanilla to the butter-sugar mixture. Stir until well combined.
Gradually add the dry ingredients to the wet ingredients, mixing gently to avoid overmixing.
Fold in the mashed bananas and pineapple. If using add-ins like nuts or coconut, fold them in now.
Pour the batter into the prepared pan and spread it evenly.
Bake for 60-70 minutes or until a toothpick inserted into the center comes out clean.
Let the bread cool in the pan for 10 minutes, then transfer to a wire rack to cool completely.