Preheat your oven to 350°F (175°C). Grease a 9x13-inch baking dish with cooking spray or butter.
In a large bowl, combine the thawed hash browns, half of the cheddar cheese, and the diced ham or bacon. Mix well and spread the mixture evenly in the prepared baking dish.
In another bowl, whisk together the eggs, milk, garlic powder, onion powder, salt, and pepper until well combined.
Pour the egg mixture over the hash brown mixture in the baking dish, ensuring it is evenly distributed.
Sprinkle the remaining cheddar cheese on top.
Bake in the preheated oven for 45-50 minutes, or until the eggs are set and the top is golden brown.
Let the casserole cool for 5-10 minutes before slicing. Garnish with chopped chives if desired.