—used conventionally as an utterance at meeting or parting
I said ciao and waved goodbye.
borrowed from Italian, borrowed from Upper Italian ćao, ćavo, reduced form of sćavo, sćao, literally, "slave," as a formulaic polite greeting, altered from Medieval Latin sclavus — more at slave entry 1
By implication, Upper Italian sćavo, sćao presumably formed part of a collocation equivalent to "I am your servant." Cf. the parallel use of Servus as a greeting in parts of southern Germany and Austria.