Answer: The colors you see in flowers come from the DNA of a plant. Genes in a plant's DNA direct cells to produce pigments of various colors. When a flower is red, for instance, it means that the cells in the petals have produced a pigment that absorbs all colors of light but red.
The petals of the flower are colorful because of their DNA and those colors can mean many things. a lot of flowers have these bright colors to attract pollinators… fun fact if you are wearing a shirt with colorful flowers you probably with have more bees and other pollinators attracted to you