Solar energy, as in raw energy emitted by the sun, is probably the least 'green' in terms of the ecology of earth. If the sun were left unchecked, its emissions of highly charged fast moving particles would strip away the atmosphere, and its high energy electromagnetic radiation would break down organic molecules, including the DNA of living things. But fortunately earth has a magnetic field the deflects the charged particles and lets us keep our atmosphere, and our oxygen containing atmosphere creates an ozone layer upon contact with high energy electromagnetic radiation which brings the energy levels down to where most people can enjoy a day at the beach. So even at 93 million miles distant, the giant fusion reactor is still a pretty hazardous way to get energy. And heaven forbid it go out of balance and supernova, which does happen fairly frequently in the universe, cause then it is game over.
On the other hand, energy sources for industrialized societies of humans are also not very green in the sense of preserving earth's ability to support future generations of human life. The carbon we like to take out of the ground and burn for energy was once part of an atmosphere that would not support human life. So by burning it we are saying that we will risk restoring the atmosphere to one that didn't support human life so that we can have labor saving devices and cool technology. That is not very green in the sense of supporting human life, but it might be the most green thing that can be done to restore earth to its natural state. If we eventually remove all humans life, earth will go through the phases of bringing a balanced ecology back into existence. It will be beautiful, but nobody will be there to enjoy it.
So if by 'green' we mean that we want both a balanced ecology and an ecology that supports human life into the future, converting energy from our hazardous sun directly into energy usable in our machines, and skipping the step of burning carbon, is probably the most green solution. As we convert more and more of our energy sources to this direct method, the products we produce will have less negative impacts on our future existence. Whether our future existence is beneficial for earth is a different type of ethical question entirely.