There's a large rulebook for the actual rules of the game. The individual Codices are for individual armies like unit entries, point cost, army composition, special rules, etc.
Every rulebook and codex that GW releases is filled with background and miniature showcases/galleries. I'd say half of the content is rules and the other half is background.
This is part of my collection:
Not sure where the third 40k rulebook is, but that's three editions of 40k, three editions of Fantasy, a few Fantasy books, lots of 40k Codices, the original Necromunda rules along with a printed version from the website (white binder), Apocalypse, Cityfight, Cities of Death, a Forgeworld book, both Aeronautica Imperialis books, Firestorm Armada rules, Uncharted Seas rules, the Flames of War rulebook, and some European and African front army books. Looking at it now, there are several books missing. D: