Probably belongs to the word family of 格 (OC *klaːɡ, *kraːɡ, “to go, to come”). Schuessler (2007) cites Tibetanདགྲ(dgra, “enemy”) as a possible cognate. Starostin compares this with Turkishkarak(“robber”) and reconstructs Proto-Altaic *kàra.
This is used as part of a form of address for a customer, like sir or ma'am. Because a customer is in a much higher social position, this word is used with the honorific prefix 御(o-) and the honorific suffix さん(-san) or more often 様(-sama), rendering お客さん(okyaku-san) or お客様(okyaku-sama).