To see color, you have to have light. When light shines on an object some colors bounce off the object and others are absorbed by it. Our eyes only see the colors that are bounced off or reflected.
The sun’s rays contain all the colors of the rainbow mixed together. This mixture is known as white light. When white light strikes a white object, it appears white to us because it absorbs no color and reflects all color equally. A black object absorbs all colors equally and reflects none, so it looks black to us.