One way to distinguish between the herpes virus (and hence herpetic gingivostomatitis) and varicella virus is by direct immunohistochemistry using fluorescent antibodies. Differential diagnosis
Diagnosis of HG is very much clinically based. Therefore, it is imperative to rule out other diseases that present similarly, bearing in mind the past medical history of the patient. Some differential diagnoses to bear in mind when considering herpetic gingivostomatitis are:

Teething in infants:  A study mentioned that  "primary  tooth  eruption begins  at  about the  time that  infants  are  losing  maternal antibody protection  against  the  herpes  virus. Also, reports  on  teething  difficulties  have  recorded  symptoms  which  are  remarkably  consistent  with  primary oral  herpetic  infection  such as  fever,  irritability,  sleeplessness,  and difficulty  with eating." Another study highlighted that "younger infants  with  higher residual  levels  of  antibodies  would experience  milder infections  and  these  would be  more likely  to  go unrecognized  or  be  dismissed  as  teething  difficulty." Herpangina: It is a disease that is caused by the Coxackie A virus rather than a herpes virus. In herpangina, ulcers are usually isolated to the soft palate and anterior pillar of the mouth.
Piedraia hortae is a superficial fungus that exists in the soils of tropical and subtropical environments and affects both sexes of all ages. The fungus grows very slowly, forming dark hyphae, which contain chlamydoconidia cells and black colonies when grown on agar. Piedraia hortae is a dermatophyte and causes a superficial fungal infection known as black piedra, which causes the formation of black nodules on the hair shaft and leads to progressive weakening of the hair. The infection usually infects hairs on the scalp and beard, but other varieties tend to grow on pubic hairs. The infection is usually treated with cutting or shaving of the hair and followed by the application of anti-fungal and topical agents. The fungus is used for cosmetic purposes to darken hair in some societies as a symbol of attractiveness. Morphology
When grown on agar at 25 °C (77 °F) Piedraia hortae grows very slowly to form black-greenish, limited and pointed colonies. Piedraia hortae taken from infected hairs have dark brown nodules, which are made up of ascostroma. The nodules have a gritty feel, organized in a stromatic fashion and have a high concentration of chitin and melanoid pigments. The colonies produce a red pigment and remain smooth and covered with short aerial hyphae. Microscopically, P. hortae produces short, dark hyphae containing thick-walled resting cells. The ascomata consist of irregularly shaped pseudothecia that are black in colour. Each ascoma contains a single ascus containing eight ascospores. The ascospores are dark, curved and become very narrow at the ends forming whip-like appendages.