JLabel is colourless and transparent by default, so you can see the text in JLabel without background colour.
myJLabel.setOpaque(true);
MyJLabel.setBackground(Color.yellow);
This will make the myJLabel become yellow in background colour
myJLabel.setOpaque(false);
will myJLabel become transparent
myJLabel.setForeground(Color.blue);
If the color of text of the myJLabel is equals to the place(e.g. JPanel)where the myJLabel is placed and myJLabel.setOpaque(false), the JLabel seems to be transparent.