Bluegill are in the family Centrarchidae, along with largemouth and smallmouth bass, crappie, and other sunfish. Cichlids form the family Cichlidae. An easy way to tell sunfish from cichlids is to look at the nostrils: sunfish have two pairs, cichlids only one.
Cichlids and centrarchids are both in Perciformes, but so are a couple hundred other families and nearly half of all fish species. These two families are not particularly closely related within Perciformes. The cichlids used to be thought to be closely related to wrasses (Labridae), but this now seems to be untrue. The latest studies I have seen place cichlids in a big group including blennies, atherinomorphs (livebearers, killifish, silversides, flyingfish, half-beaks, etc.) and the snakehead-gourami-swamp eel group.
Most familiar aquarium fishes from livebearers to seahorses to bettas to dats are perciforms, except for the otariophysans (cyprinids, loaches, tetras, piranhas, catfishes) and the various "ancient" fishes like arowanas, featherfin knives, and stingrays.