Add the shredded coconut to a dry pan or skillet over medium heat. Stir frequently until it turns golden brown and fragrant, about 3–5 minutes. Remove from the pan immediately to prevent burning.
In a small saucepan, combine the water, cane sugar, brown sugar, and salt. Bring to a gentle simmer over medium heat, stirring until the sugar dissolves completely.
Once sugar is fully dissolved, add the toasted coconut to the syrup and simmer gently (not boiling) for 5-7 minutes to infuse. The syrup will start to deepen in color and take on a toasty aroma.
Remove the saucepan from the heat and stir in the vanilla extract. Let steep for 10 minutes, then strain through a fine mesh sieve or cheesecloth to remove the coconut flakes.
Once cooled, transfer the syrup to a glass jar or bottle. Store in the refrigerator for up to 2 weeks. Shake before each use.