SAN FRANCISCO -- Google Inc. has been searching for the right way to cuddle up in your living room.

After a string of high-profile flops, the technology giant may have finally hit on the answer: a tiny, inexpensive device that plugs directly into high-definition television sets and streams video and other digital content from mobile devices.

At a splashy event in San Francisco on Wednesday, Google unveiled Chromecast, a 2-inch-long, $35 gadget that enables users to connect Apple and Android devices to the biggest screen in their home without ever touching the remote control.

Analysts say the move dramatically heats up competition among technology companies to get content from mobile devices to TV sets.

Chromecast is a shot across the bow to Apple Inc., which is gearing up to unveil new television technology; Amazon.com Inc., which is preparing a set-top box to stream video; and Microsoft Corp.'s newest game console, the Xbox One, which aspires to be more than just a plaything.

But more importantly, Chromecast could give Google the opportunity it has long sought: to open up television as a new channel for selling ads, its biggest source of revenue.

Google is looking to tap into the billions of dollars marketers spend each year on TV advertising. In the U.S. alone, that spending exceeded $74 billion last year, an 8% jump from 2011, according to researcher Kantar Media.

Getting a warm spot on the living room couch would have other benefits for Google. The average American spends about 4 hours 39 minutes every day watching TV, according to measurement firm Nielsen.

Google needs to understand how these consumers are spending their time to deliver the best recommendations, the most relevant search results, and apps finely tailored to an individual's tastes and preferences, Forrester Research analyst James McQuivey said.

"This is all about knowing you and knowing what to give you next," McQuivey said. It's also about helping Google's own content make the leap to the big screen.

Google has been positioning YouTube as a digital media hub: investing an estimated $200 million to bring professional-quality original content to the site, and striking deals with all the major Hollywood studios to sell and rent movies, and offer past episodes of popular network TV shows, which are available on YouTube (and Android mobile devices) through Google Play.

The long-rumored YouTube subscription channels launched in May. Viewers pay as little as 99 cents a month to watch video from the Ultimate Fighting Championship or Sesame Street.

Chromecast brings Google the final mile, providing it another way to deliver these videos to the TV.

"One of the key things is engagement: How long people watch -- because how long they watch translates into how many ads they see," said Colin Dixon, chief analyst for researcher NScreenMedia. "If you put people in the sit-back environment of their living room, with a television, they're just going to watch more."

The more videos people watch, the more potential advertising revenue there is for Google and its partners.

"YouTube gets really hard to ignore if it really is on every screen," Dixon said. "And the TV is perhaps the last unconquered screen for YouTube."

But Google has struggled to get inside the living room. The Nexus Q, which was supposed to stream digital music and other content to home entertainment systems, was indefinitely postponed after negative reviews. Google TV, software that Google embedded into sets made by TV manufacturers, also flopped, as did a Google TV set-top box.

Google says it has not given up on Google TV, which turns the TV into an Android device that can play apps and other content.

But analysts say Chromecast, a small stick about the size of a thumb drive that went on sale Wednesday at Amazon.com, BestBuy.com and in the Google Play store, may be more promising. It works not only with a range of devices, YouTube and the Google Play store but also with Netflix and other popular services, so you can use any smartphone, tablet or laptop computer to binge on Netflix's "Orange is the New Black" or check out the latest dog videos on YouTube.

"What they've realized is all of their prior attempts required way too much from the user: too much faith, too much money, too much cooperation from industry partners," McQuivey said. Google "looked at those things and said, 'How do we make it cheaper, make it drop-dead simple and make it something the industry can't object to?' "It's impressive that a big old dog like this can learn new tricks."

Chromecast competes with a number of other devices that deliver Internet content to the TV screen, including game consoles such as Microsoft's Xbox 350 and the Sony's PlayStation 3, Internet-connected Blu-ray players and dedicated streaming devices such as Apple TV and Roku HD.

"The fact is, more and more devices are connecting," said Stephen Baker, an analyst with NPD Group Inc. "People want content on more and more screens, and we shouldn't ignore the fact that getting content to the television is pretty important, because the television is the best screen in your house."

Other analysts say there's not much to distinguish Chromecast, beyond its low price. Roku, for example, offers access to other video-streaming services, such as Amazon Instant Video and Hulu Plus, as well as unlimited access to HBO content through HBO Go, a digital offering for TV subscribers.

"Thirty-five dollars is undoubtedly a great price," said Dan Cryan of IHS Screen Digest. "At the moment, unless you're very tied to the Google ecosystem or Netflix, it's perhaps not the most compelling. When you start adding more services to the thing, the offer gets better and better."

The rollout is the latest example of Google's headlong plunge into manufacturing hardware. Google worked with a hardware maker in Taiwan to build Chromecast and hopes to eventually put the technology inside new TVs and mobile devices. This year, Google introduced a Chrome laptop that it designed and manufactured with an Asian partner. In 2014, Google plans to release Glass, its wearable computing device.

Google is taking on Apple and Amazon.com in another major battleground: the mobile computing market.

Google on Wednesday also showed off a new, more powerful version of its Nexus 7 tablet. The tablet goes on sale in the U.S. on Tuesday. It boasts a higher-definition screen and a processor that Google says is nearly twice as fast as the previous version. Google has also added dual stereo speakers for bigger sound.

The announcements came a week before Google's Motorola division unveils the Moto X smartphone in New York. The Moto X is the first phone that Motorola has developed since it was bought by Google for $12.5 billion in May 2012.