When Comcast Corp., the United States' largest cable operator, took a stake in NBCUniversal in 2009, "30 Rock," a popular NBC comedy, wove the deal into its plot. The program's characters came under the thumb of a new corporate parent, "Kabletown," which introduced innovations like moving customer services to a part of India with no phones in order to "provide the same level of service at zero cost."

Comcast employees can take a joke. Last month, at a gathering to celebrate Comcast's 50th anniversary, they showed a clip of the show, to the amusement of the firm's real employees. A sense of humor is a sign of confidence.

Thanks to the $28 billion it spent to acquire NBCU, Comcast is the world's largest media firm, with a market capitalization of about $128 billion. NBCU gave Comcast control of a range of new "content," including broadcast and cable networks, a Hollywood studio and a theme-park business.

Comcast is also the nation's most powerful media business, because it controls what people watch and the pipes that deliver it. In its efforts to retain that position it is having to adapt to the new ways that people want to watch TV and consume entertainment that smaller rivals are pioneering.

The cable business has changed dramatically since Ralph Roberts purchased a small cable system in Mississippi in 1963. Today his son, Brian, runs a firm operating in a vast and mature business; nearly 86 percent of U.S. households subscribe to pay TV. This has forced Comcast and other cable firms to increase revenue by raising prices rather than by chasing new viewers. But not every viewer will tolerate high prices. The proportion of households with pay TV has fallen slightly since 2010 as some have "cut the cord." Comcast now has 21.6 million subscribers, 1.6 percent fewer than a year ago.

Comcast is the largest cable and high-speed Internet service provider in Minnesota, with about 2,000 employees. Besides its consumer cable TV, Internet and telephone services, Comcast's Twin Cities operations in St. Paul provide other consumer services, including the X1 cloud-based video service, portable TV Everywhere offering and Xfinity Home security and management service.

In addition, the company provides business services in the Twin Cities that include corporate phone, Internet and video offerings and its Upware cloud-based business software.

Citing competitive concerns, Comcast declined to say how many consumers or businesses subscribe to these services. It said that its network passes more than 1.1 million homes in the Twin Cities.

In addition to cord-cutters, Comcast and other cable providers must defend their turf from a pack of new entrants. These include telecom firms such as Verizon and AT&T, which offer pay TV and fast broadband, and firms that stream video over the Internet, such as Netflix and Amazon. These companies have not killed cable, but they have helped to shape the way people want to watch programs: increasingly, on mobile devices and at a time of their choosing.

Netflix is popular with the young. Around 20 percent of households headed by people under 25 do not have a television but watch programs on other devices, such as laptops and tablets. If Netflix were a cable channel, its subscription revenue in 2013 would put it third in the United States behind ESPN and HBO, according to MoffettNathanson, a research firm.

Comcast has responded by trying to resemble the firms that could unseat it, offering more interactivity, personalization and portability.

"Television is going to change more in the next five years than it has in the last 50," said Brian Roberts. Comcast executives talk about "apps" for the television and rolling out innovations every three to six months. The firm is paying particular attention to its user "interface" or what, until recently, was called a TV guide. Comcast's is now arranged not numerically by channel, but alphabetically by program, by network and type of content. Couch potatoes even less inclined to click through a menu can download an app to their iPhone and shout commands at it to locate shows.

Comcast's new set-top box is "cloud-based," adding to the potential for flexibility: Films and programs stored in the cloud can be watched on any device. It tracks viewing history and recommends programs accordingly, much like Netflix. Comcast has made it easier for TV-watchers to find their way to full seasons of episodes that are available on-demand so people can "binge" on shows.

Other pay-TV providers are experimenting with new features, and some have approached Comcast to license its technology. One popular idea is "TV Everywhere," which makes it possible for pay-TV subscribers to watch live and on-demand programs on their mobile devices wherever they like. It has started slowly but is taking off as more content owners agree to license the digital rights to their programs. Tools like this may help Comcast and its rivals justify their high prices and convince people to stick with their television package.

Giving customers more products to keep them around for longer is an old tactic. Cable companies have long offered "bundles" of broadband, television and phone line. Comcast is going much further with its home-services business, which includes alarm systems, baby monitoring and temperature control.

And it is bringing in partners. In October Comcast teamed up with Twitter to allow its subscribers to find or record programs that are being tweeted about. Like its competitors it is also testing smaller, cheaper packages of television channels and broadband, to appeal to cost-conscious youngsters.

The greatest change for Comcast is the reorientation of its business toward broadband. By next year Comcast may well have more subscribers to its broadband services than for television. Those who eschew pay-TV will still need an Internet package, and cable could pick up customers from satellite operators, whose Internet speeds are slower.

"Ironically, content going to the Internet gives cable companies that monopoly power back to a certain extent, because you don't have competition in broadband to the extent you have it in video," says Kannan Venkateshwar of Barclays, a bank.

Comcast and other cable companies are experimenting more with "usage-based pricing," charging more for heavy data consumption.

Staff writer Steve Alexander contributed to this report.

Copyright 2013 The Economist Newspaper Limited, London. All Rights Reserved. Reprinted with permission.