how to set a color backround JFrame in java code example Example: how to set frame colo in java getContentPane().setBackground(Color.YELLOW); //Whatever color