There are certain shows with really clear origins. Almost everything on the CW, for example, comes from comic books. And then there are the shows that are weird and creative enough that you have to wonder a) how anyone came up with them, and b) how anyone put them on TV.
Thankfully, we have this Court of Source video to explain how Rick and Morty came into existence. It involves a cease and desist letter from Bill Cosby, Back to the Future, and a single day in Dan Harmon’s office.