late Old English heorcnian "to give ear, listen" (intransitive); hear with attention" (transitive), a suffixed form of *heorcian (root of hark); from Proto-Germanic *hausjan (see hear). Harken is the usual spelling in U.S. and probably is better justified by etymology; OED says preference for hearken in British use likely is from influence of hear.
Others are reading
<a href="https://www.etymonline.com/word/harken">Etymology of harken by etymonline</a>
Harper, D. (n.d.). Etymology of harken. Online Etymology Dictionary. Retrieved $(datetime), from https://www.etymonline.com/word/harken