You're on grid the whole time, but contributing power of your own. Solar won't stay on when the grid goes down unless you get a backup system, which is more expensive. Just get a standard grid-tied system and look into the wide world of financing options.
Yes, solar inverter power is kind of dirty. But so is the power from the utility transformer outside your house. They all produce harmonic distortion. Also, your refrigerator, ceiling fan, and possibly your neighbor's vacuum cleaner are adding noise to your power. If I were concerned about power quality I'd just get a power conditioner.