Sir Paul McCartney's cell phone was hacked into "for years" by a private detective working on behalf of disgraced British tabloid the News of the World, a court heard on Friday (01Nov13).

The Beatles legend was first targeted in 2002, as his relationship with Heather Mills progressed towards marriage, and the surveillance continued until at least 2004, a jury at London's Old Bailey was told.

Prosecution lawyer Andrew Edis Qc told the court, "Paul MCCartney and Heather Mills were the subject of phone hacking for years. I refer you back to the wedding ring story in 2002. (The newspaper was) still hacking (in 2004)."

The sensational allegation has come in the first week of the high-profile 'phone hacking' trial arising out of the scandal that closed the Rupert Murdoch-owned tabloid in 2011.

It is alleged some senior staff at the newspaper commissioned a private investigator to access cell phones of the rich and famous to listen to their voicemail messages.

Former News International chief executive Rebekah Brooks, ex-News of the World editor Andy Coulson, and six other former Murdoch staff are on trial over the scandal.

They deny all charges. The trial continues.