Preheat the oven to 350°F.
Place the onions in a large bowl. Sprinkle with the salt, mustard, garlic powder, and paprika; toss gently to coat. Arrange the onions evenly in a 9x13-inch baking dish.
Arrange the butter pieces evenly over the onions and sprinkle with 1 ½ cups of the havarti and 1 ½ cups of the cheddar cheese. Cover with aluminum foil and bake until the onions are soft and the sides of the baking dish are bubbling, about 40 minutes.
Remove the foil and top with the remaining ½ cup havarti and ½ cup cheddar cheese. Bake until the top is golden, about 30 minutes. If you’d like the top more browned, increase the oven temperature to broil on high during the last 5 minutes of cooking. Sprinkle with parsley, if desired, and black pepper and serve.
