Hilary B. Rosen, who as chief executive of the Recording Industry of America fought illegal Internet file sharing, will quit at the end of this year, the organization said yesterday. It will end a tumultuous time for Rosen, in which she became the public face for an industry struggling to protect its market.

As one of the highest-paid lobbyists in Washington, Rosen led the music industry's legal battles to prevent digital piracy of recording music. She said musical artists are not fairly compensated for their work.

"Hilary is a remarkable leader and when she leaves at the end of the year, she will take with her our sincere gratitude, respect and admiration," Roger Ames, chief executive of Warner Music Group, said in a prepared statement.

Rosen, 44, joined the RIAA in 1986 and has led it since 1998. She has not revealed her plans other than to spend time with her twin 4-year-olds. Her partner -- Elizabeth Birch, executive director of the Human Rights Campaign, the nation's largest gay-advocacy group -- announced in December that she would leave her job at the end of 2003.

"We decided we wanted to make a change as a family," Rosen said in an interview. She said it's not clear whether that includes remaining in Washington, where she and Birch are a power couple on the social circuit. "She'll figure out what she'll do and I'll follow."

Rosen said she would have preferred to announce her resignation closer to summer but was pressured into making it now to keep it from leaking.

Under Rosen, the music industry battled aggressively to stop people from trading songs over the Internet, a phenomenon that companies estimated cost them $5 billion in lost sales last year worldwide. The RIAA fired off threatening letters to colleges and universities, calling on them to crack down on students who shared songs, and went to court to force Internet service providers to divulge the name of alleged offenders.

In the process, she alienated music fans and even some in the entertainment industry who believed that the big labels that the RIAA represents -- Universal Music Group, Sony Music Entertainment Inc., Warner Music Group, Britain's EMI and Germany's Bertelsmann AG -- were refusing to adjust to the realities of a digital marketplace.

"She has managed to demonstrate leadership in an industry wrought with chaos," said Los Angeles entertainment lawyer Kenneth Hertz, whose clients frequently clashed with the RIAA. "She did a great job fighting a losing battle. Her victories were pyrrhic."

Jonathan Potter, president of the Digital Media Association, which fought the RIAA on several issues, said Rosen "managed through a terrible nightmare. She's young; she should take a few years off and be with her children."

Though Rosen was publicly praised by music executives yesterday, many have privately said she hasn't done enough to protect the industry and that her aggressive stance has alienated music consumers.

"As in 'If she's so great, why is this getting worse?' " Rosen acknowledged yesterday.

The recording industry faces serious financial problems. Sales of compact discs have dropped over the past two years -- from 763 million in 2001 to 681 million last year, according to Nielsen SoundScan. The industry has begun to build its own online file-sharing services, which typically charge fees for downloading songs.

"We have to invest in transitioning our consumers from the online pirate market into the legitimate market," Rosen said. "We have to be undaunted and strategic in our enforcement efforts to protect the legitimate market and we have to adjust our marketing and sales strategies to the new realities of a very different retail marketplace and consumer base."