Sometimes they will seem to contradict each other. For example, the amount of necessary detail may preclude economy of exposition. The art of good essay writing lies in the ability to achieve the necessary balance consistent with the overall objectives of the essay. References relate to those authors whose work you have directly referred to in your text. The bibliography, however, is an acknowledgement of the general literature which you have read and which influenced your thinking on the topic being addressed.
Some texts separate the two.
You should be careful to distinguish the two, as most essays require only a list of references at the end of an essay and citations in the text. All HPSC essays require a list of references at the end and citations to those references in the text. The aim of referencing is to enable a reader to trace back to the author's original sources. Hence enough information needs to be provided to facilitate this. A good source on referencing is the Chicago Style Manual which is available in the DMS Watson Science Library.