Data Had An Entirely Different Backstory Planned Before Star Trek's Datalore
In the "Star Trek: The Next Generation" episode "Datalore" (January 18, 1988), the Enterprise-D is called to a distant colony where the android Data (Brent Spiner) was found years earlier. When Data was first discovered, he had no memories, although he knew he was constructed by a rogue genius named Dr. Noonien Soong. Soong was blackballed from the scientific community many decades earlier and had to retire to a distant colony to continue his work. Back when Data was discovered, by a starship called the U.S.S. Tripoli, the colony had been destroyed and Soong was missing, presumed dead. Data had no memories of what happened.
In "Datalore," the Enterprise found something else surviving among the rubble. Pieces of a second android, identical to Data, were found in a previously sealed area. Data and the Enterprise engineers reassemble it and find that it is Lore (also Spiner), another Soong android. Lore, unlike Data, is passionately emotional, and even a little sarcastic. He claims to be the secondary Soong model after Data proved to be imperfect. Data is keen to learn more about his origins from Lore.
Perhaps predictably, Lore turns out to be a liar and a villain. He was long in league with a massive crystalline entity that ate planets and lured the creature to his colony to eat up his human counterparts. He aimed to supplant Data and punish him for "dad always like you best" reasons. All Trekkies know Data's origin.
According to Larry Nemecek's invaluable sourcebook "The Star Trek: The Next Generation Companion," however, Data's origins used to be far different. During the early development of "Next Generation," Data was to have been built by an unknown race of space aliens.
The lore of Data
In some of the earliest production notes for "Star Trek: The Next Generation," written back in 1987, Data was described as having been built by a species of aliens that audiences would never see. The aliens were described as "Earth Asian," and Data was intended to be played by an Asian actor. Actor Kelvin Han Yee famously auditioned for the role. John Lone was briefly in consideration as was Kim Miyori, back when Data was (very briefly) transformed into a female character. The final audition actually came down to Spiner and Mark Lindsay Chapman. When Spiner was selected, only then did the physical design for Data begin in earnest. Makeup artist Michael Westmore was the one who invented Data's pale skin and yellow eyes.
The aliens who built Data would have also implanted his brain with the memories of their homeworld, and Data would have an amalgamated personality of every surviving member of the species, now presumably lost forever. That's an ambitious sci-fi idea, but perhaps difficult to portray in an everyday performance on primetime TV. That kind of concept is far better suited for sci-fi literature.
Some of that origin story made its way into the script for "Datalore." By on-screen Trek mythology, Data actually did have the personal logs of the lost members of his "childhood" colony implanted into his positronic brain. Data, however, had no emotions, and could only access the logs when asked. The colonists' memories didn't dictate his personality. Also, they were all humans in the final draft. No aliens in sight. Well, other than the crystalline entity that killed them.
Data's Day
The writers of "Star Trek: The Next Generation" adored Data, and the character got more "starring" scripts than any other character, save Captain Picard (Patrick Stewart). Spiner was also eager to stretch past playing a Pinocchio-like emotionless character, and was happy to play an "evil" character like Lore. Spiner would also eventually appear as the very elderly Dr. Soong in the episode "Brothers" (October 8, 1990). In that episode, it was explained that Lore was the imperfect prototype, and Data was the improved version. That knowledge gave Data an android version of a catharsis.
Spiner would also play multiple Data-like versions of Old West characters, thanks to a holodeck glitch, as well as another Soong prototype called B-4, introduced in the 2002 movie "Star Trek: Nemesis." Spiner played multiple members of Soong's extended family, stretching across a century, thanks to "Star Trek: Enterprise" (set about 200 years before "Next Generation") and "Star Trek: Picard" (set several decades after). His final form, from "Picard," was a super-advanced, mostly organic android with all the memories of Data, Lore, B-4, Soong, and others forced into his brain.
A few other androids have appeared since the inception of Data, but fewer than you might think. Thanks to the episode "The Measure of a Man" (February 13, 1989), wherein Data's sentience was put on trial, both fictional Starfleet officers and very real Trekkies have been cautious about manufacturing new living, artificial beings. It's also been repeatedly established that building a Soong-type android is very difficult, assuring that "Star Trek" wouldn't be overrun with androids. The stinginess paid off, and Data has remained a standout across the franchise.