Samsung once had the opportunity to buy Android before Google but the electronics manufacturer just laughed at the idea two weeks before Google snapped up the mobile operating system.

According to the book Dogfight: How Apple and Google Went to War and Started a Revolution by Wired's contributing editor Fred Vogelstein, engineer Andy Rubin, who started the Android project in 2003, pitched the mobile operating system idea to Samsung first.

"I pitch the whole Android vision to them like they are a venture capitalist. And at the end and I am out of breath, with the whole thing laid out ... there is silence. Literally silence, like there are crickets in the room," said Rubin, who had flown out to Seoul with his team in 2004 to pitch to the electronics giant.

"Then I hear whispering in a non-native language, and one of the lieutenants, having whispered with the CEO, says, 'Are you dreaming?' The whole vision that I presented, their response was, 'You and what army are going to go and create this? You have six people. Are you high?' is basically what they said. They laughed me out of the boardroom."

The future of mobile

Fortunately for Rubin, in early 2005 Google's Larry Page saw the potential in Android. Google had been envisioning what the future of mobile would look like - and it was exactly what Android was offering.

Back then, small-screen phones with slow internet that showed only the bare bones of websites were the norm, and the whole mobile surfing experience was still quite limited.

Rubin and his team had been working on a new operating system that was designed to work on any kind of mobile device, complete with a full internet browser and multiple applications running at the same time.

Google acquired Android for $50 million (£30m) two weeks after the Samsung presentation - and the icing on the cake for Rubin was receiving a call from Samsung the day after the acquisition was announced, demanding that he meet with them to discuss his "very, very interesting proposal".

Of course, Samsung has done pretty well out of Android itself since then, being the world's largest smartphone manufacturer, but it's interesting to think about what the world would be like today if Samsung had said yes.

Google's challenge

According to Vogelstein, who interviewed numerous sources in Google for his book, back in 2005 Google was keen to bring an innovation to the mobile industry that would revolutionise the mobile experience, and was deeply afraid that Microsoft would beat it to the chase.

There was also the problem that Apple was already working on the iPhone, and although the smartphone was a bet-the-farm move for Apple, at least the electronics company had experience making consumer products, whereas Google's offerings were all web-based and free.

When the first iPhone launched in 2007 the Android team, who had now been working on the operating system for four years, began to wonder if they needed to start all over again, as they had severely underestimated Steve Jobs.

"We knew that Apple was going to announce a phone. Everyone knew that. We just didn't think it would be that good," said Ethan Beard, one of Android's early business development executives.

"Frankly, the iPhone created a morale problem," said one of the senior engineers. "Some of the engineers actually said, 'Oh my God, we're doomed. This is Apple. This is the Second Coming. What are we going to do now?'"

However, many of the innovations that later went into the iPhone had first come from other Silicon Valley inventors, and Rubin and many of his colleagues have long seethed with frustration that Jobs claimed credit for the technology of the iPhone, most of which had not been invented by Apple.

What Jobs had done was to design a great piece of hardware and add to it lots of different software capable of performing a multitude of functions, package it all together and make it into a device that consumers yearned to have.

Sidekick: The birth of Android

Prior to starting work on Android, Rubin had worked at another start-up, Danger, where he had helped to launch the Danger Hiptop, more commonly known as the T-Mobile Sidekick, a phone which looks like a cross between Nokia's ill-fated N-gage handheld mobile game console and the Sega Game Gear from the 1990s.

Launched in 2002, the Sidekick allowed users to surf the internet the same way they did on their desktop and laptop PCs, by typing on a QWERTY keyboard and looking into a screen that flipped open and turned 180 degrees. The device wasn't a big success but soon had a cult following among techy university students and Silicon Valley engineers, including Google's Page and Sergey Brin.

The Sidekick, which was sold by T-Mobile until 2011, was also the first phone to have downloadable games.

Rubin and his team at Danger see themselves as being the ones who invented the first usable internet browser on a phone in 2002, undermining Jobs' claims of the iPhone having the "first fully usable" internet browser on a phone.

"Only one in ten engineers have probably even heard of Danger now, yet many of the things associated with the modern smartphone we did first on the Sidekick," said Chris DeSalvo, a Google engineer who worked with Rubin at Danger.

"Obviously we were five years too early. If we had launched in 2005, though, we would have owned the world. I guess I don't think we get enough credit for what we did."