In the US, it is or is not, depending on the jurisdiction. One question is what to call it. In Oregon it is called "harassment"
A person commits the crime of harassment if the person intentionally:
(a) Harasses or annoys another person by: (A) Subjecting such other
person to offensive physical contact...
In Washington, there is no statutory definition of assault, which is thus left to the courts who follow common law interpretation that is is An intentional, unlawful touching that is harmful or offensive, and spitting is 4th degree assault because it isn't a higher degree of assault (it doesn't cause bodily harm and isn't against various specified (semi-)officials).
In Ohio, spitting and water balloon attacks appear to be legal. There have been multiple attempts to prosecute people for spitting under the assault statute, which prohibits "caus[ing] or attempt[ing] to cause physical harm to another". Various rulings have excluded offensive contact, see Ohio v. Sepulveda
In our own review of the case, and the caselaw that exists on the
topic, we cannot categorically find that spitting on someone
would never constitute an Assault, and to the extent that
either the Bailey or the Wyland decisions can be construed to
be based on such a determination, we expressly decline to adopt them.
Certain instances of spitting could cause physical harm, but in lieu of harm, spitting is not assault.
Each state gets to define it's own. Here's an article about North Carolina spitting law: assault there is defined via common law but does not include offensive contact. There are no clear court cases, but a couple of rulings that suggest that the courts might accept an assault conviction.
It also may matter exactly where you are. In the case of US v. Lewellyn, defendant was in the state of Washington, but on the grounds of the Veterans Administration Medical Center in Walla Walla, Washington. He was convicted of a federal crime, violation of 18 USC 113(a)(5). Being at the VA hospital, he was
within the special maritime and territorial jurisdiction of the United States, making a federal case out of it. The appeals court approved the trial court's application of the common-law "offensive contact" branch of the definition of assault. (The ruling also cites parallel findings in other US circuits). The outcome is the same as would be the case under state law. But, this also indicates that spitting on federal property in Ohio is a federal crime, though not a state crime.