Great question!
Short answer: One comes from the Latin stare meaning "to stand" and one comes from the Latin essere meaning "to be".
The long answer, as with a lot of confusing grammatical points of Romance languages like Spanish, lies in its roots and history.
Spanish is one of the Romance languages that we speak today (Romance not meaning "love" in this case, but meaning "comes from Latin" or really, the empire that spoke Latin- Rome"). Rome was a huge empire and covered most of the "known world" of the west and most people spoke common Latin (called Vulgar Latin) to communicate across the empire. Thus, someone from the Iberian peninsula where Spain is could communicate with another subject of the empire in modern day Romania, or Lebanon, or London.
As Rome declined and time went on, localized dialects turned into distinct languages. That's why we have Portuguese, Spanish, Italian, French and Romanian today. Each of them share characteristics of that Roman language.
Latin had one word meaning "to be". That was essere. You can see how that, over time and with a local dialect, could turn into our modern ser. Just drop the "es-" from the beginning and the "-e" at the end, and there's the verb. In Iberia, however, another word was also adopted to mean "to be" in terms of being "in state" or "standing" (like if we say "the building is standing" in modern English. It isn't "standing" like people stand, but it's there). That word in common Latin was stare and, if you add the "e-" at the beginning of the word** and remove it from the end, you've got our modern estar which we use to mean a physical location, and also use as the root of the word estado, meaning "state". Over time the two countries that would come to exist on the Iberian peninsula retained both verbs and use both in different situations. That's why Portuguese and Spanish have them, but Italian, French and Romanian only have one.
**Latin words that begin with "s" picked up an accent when spoken in the Iberian peninsula, and the [e] sound was added to a lot of words that begin with "s". For example, stare would have been pronounced [e]stare, "eh-star-ay". There are other examples as well: spiritu became espiritu, and even the name of the area took on that sound. Hispaniam in Latin became España.
Nalini S.
SORRY! Italian DOES have TWO verbs: STARE and ESSERE. https://it.bab.la/esempi/italiano/stare Ecco come devono stare le cose. Credo che sia meglio stare in guardia. Lasciamo stare le regole come sono! Dobbiamo stare attenti ad evitare le contraddizioni. This is how things must be. I think it is better to be on guard. Let's leave the rules as they are! We must be careful to avoid contradictions.07/24/23