How Grid-Tied Solar PV Works
The main components of a solar PV installation are the solar panels and the inverter which converts the DC power the panels make into AC power and sends it into your electric panel for your home to use. When the solar isn’t covering 100% of your energy needs (at night, say) you’ll pull electricity from the grid like normal. This happens seamlessly so there's no need to change your daily habits.
Here’s the cool part:
When your solar is making MORE energy than your home needs the excess power flows back into the utility grid, spinning your meter backwards. Your utility tracks how much you give them and credits your account by that much. Which means the next time you need to pull from the grid they serve that credited energy back to you first AT NO COST. This process is called Net Metering and it happens all year long. If at the end of a yearly cycle, you've given the utility more than you've needed back they pay you for the excess.