Expletive "es" is grammatically a stand-in for the subject of the sentence, but it can only be used if the finite verb is in third person (singular or plural).
Es geht ein Bi-Ba-Butzemann in unserm Kreis herum ... (children's song)
Es trinken die Matrosen von allen Spirituosen am liebsten Rum ... (Shanty)
Es war(en) einmal ein Mann und eine Frau ... (beginning of "Rapunzel", a brothers Grimm fairytale)
Thus, in a sentence like:
Da sind wir am Abend wegen des scharfen Essens in dieses indische Restaurant gegangen.
... "es" doesn't fit because the subject and predicate is in first person ("we went").
"Da" as an expletive, in contrast, is grammatically still an adverb, like in the local or temporal use of "da", so it doesn't care about the person of the predicate.
That said, it's not really just a replacement of "es", it can be used in many cases where "es" could also be used, and it has at least some kind of its own separate meaning, although quite hard to define.
In the above example, "da" can have different meanings. In a specific context, for example, it could mean "so" or "given this situation":
Carla hatte nach drei Tagen keine Lust mehr auf die deutsche Kochkunst. Da sind wir am Abend wegen des scharfen Essens in dieses indische Restaurant gegangen.
At the beginning of a story or statement, it could establish a context, for example meaning something like "When this story happened, ...", similar to English "There was ..." or just using "this" in English to introduce a character. Or establishing a topic/context for a statement. For more, see the DWDS link.
Da lebte ein Fischer in einer kleinen Stadt ... (This fisherman lived in a small town ... / There was a fisherman who lived in a small town ...)
Da macht man sich die ganze Mühe, und dann wird es nicht wahrgenommen. (You go through all this work, and then it's not recognized. ("Da" says that the first sentence is the setup/situation for the second one))
Da sagen die Leute, sie sei dumm, dabei ist sie schlauer als alle anderen. (People say she's dumb, but she's smarter than all of them.)
It can also add context to an earlier sentence:
Sie war am Ende schlauer als alle anderen. Und da sagen die Leute, sie sei dumm. (In the end, she was smarter than all of them. While people say she's stupid.)