These days, many quite reputable private and state colleges offer courses and even degrees online. They call it "distance education."
At the link below, you will find distance education programs offered through absolutely respectable and fully accredited universities like the University of Maryland, Penn State University, Indiana University, Iowa State University, New York University, University of California at Davis, and even Columbia University, Stanford University, and Cornell University.
However, I would still advise you to be careful. Many graduate programs are still extremely skeptical of online education. Contact the particular graduate programs in which you are interested, and make sure they would look kindly upon coursework taken online.
Best wishes to you.