In a pot over medium-high heat, melt the butter. Add the onions and cook, stirring often, until they are almost tender, about 4 to 5 minutes.
Stir in the garlic and flour, and cook for about 1 minute, stirring continuously.
Gradually whisk in the milk and then the chicken broth. Add the broccoli and continue to stir until the mixture starts to thicken. Reduce the heat to low and cook, stirring very frequently, until the broccoli is tender, about 6 to 8 minutes.
Remove the pot from heat. Stir in the heavy cream, followed by the cheddar and Parmesan cheese, mixing until the cheeses are melted. Season with salt and pepper to taste. Serve warm, with additional cheddar if desired.