elsarticle document class is compatible with many authoryear-based bibliography and citation callout styles.
If you want to stick with an Elsevier-supplied style while creating authoryear-style citations, you could use the file
elsarticle-harv.bst, i.e., just issue the instruction
somewhere in your document.
If you wish to use some other authoryear-based bibliography style and also use the
natbib package, be sure to load
natbib with the option
Addendum: Based on your follow-up comment, I now understand that you're not only interested in the "harvard" (aka, "authoryear") citation style in general, but also in the harvard citation management package; this package consists of a style file named (unsurprisingly)
harvard.sty as well roughly half a dozen bibliography style files, one of which is
I don't know for sure if the
harvard style file is compatible with the
elsarticle document class. However, you needn't actually load the
harvard package in order to use the
agsm style. Since you're already loading the
natbib package (which is known to work well with the
elsarticle document class), all you need to do is to load the har2nat package as well. (I'll let you take a guess as to what loading
har2nat accomplishes.) By loading both the
har2nat packages, you are assured full interoperability with the
elsarticle document class and the
hyperref package -- while continuing to obtain the specific bibliography layout that's produced by the
agsm bibliography style.
Of course, for the journal-ready version of your document, be sure to load
elsarticle-harv instead of
agsm and rerun LaTeX, BibTeX, and LaTeX twice more.