When broccoli turns yellow, this is a sign that the chlorophyll pigment (which makes it green) is breaking down. There are no additional nutritional benefits of eating broccoli when it is yellow in colour versus green.
Broccoli that is starting to turn yellow can still be eaten, however, if it is also soft or mushy it is time to throw it in the compost. Broccoli florets start to become yellow after harvesting due to a loss of chlorophyll, which gives vegetables their green color. It also likely means a reduction in the broccoli’s nutrient content, especially vitamin C, but it is still a healthy choice. Use broccoli that is turning yellow as soon as possible. Rather than throwing it away, it can be added to soups or stews.