A friend emailed me a while back to ask for advice. She'd just finished a novel that quoted some lines from famous pop songs and she wondered if I'd any tips for her. I had. Just one. Don't ever quote lines from pop songs.

I wish someone had given me that advice when I was writing my last novel, South of the River, at the end of which there's a party, with music and dancing. As author you get to play DJ, and the tracks I put on for my characters were a mix of 60s classics and more recent numbers. Because the songs were there not just for atmosphere but to echo events and themes in the novel, it was important, I felt, to include the words, not just the titles.

Of course I knew that when you quote something by a living writer, or even a not-long-dead one, you need permission. Almost every book carries an acknowledgments page, and among the more personal thank yous – "to my wife for her unstinting support", etc – there's often a more formal credit to such and such a publisher, gallery or record company for permitting a certain item to be reproduced. Such permissions come at a price, and it's usually the author's duty, not the publisher's, to obtain and pay for them. But I'd restricted myself to just a line or two from a handful of songs and vaguely hoped that was OK or that no one would notice.

My editor, reasonably enough, was more cautious, and at the last minute someone from the publishing house helpfully secured the permissions on my behalf. I still have the invoices. For one line of "Jumpin' Jack Flash": £500. For one line of Oasis's "Wonderwall": £535. For one line of "When I'm Sixty-four": £735. For two lines of "I Shot the Sheriff" (words and music by Bob Marley, though in my head it was the Eric Clapton version): £1,000. Plus several more, of which only George Michael's "Fastlove" came in under £200. Plus VAT. Total cost: £4,401.75. A typical advance for a literary novel by a first-time author would barely meet the cost.

My publisher, very decently, agreed to go halves. And I've only myself to blame. But it's an interesting illustration of the power of music publishers. Or of the scary lawyers they employ. The logic of their policy is hard to follow. To reproduce lyrics in a book isn't the equivalent of downloading them, because nothing can be heard: it's up to the reader to supply the music, and it's not unfeasible that he or she might then go out and buy the relevant CD. In effect, quoting lyrics is a form of free advertising. But try telling that to the music industry. At a time when piracy, Spotify and unauthorised downloads are eroding its income, it needs every penny it can get, even if that means fleecing fellow-practitioners.

For biographers, permission fees are even more of a nightmare than for poets or novelists, especially if they reproduce images as well as words. In order to raise funds to cover the copyright and reprographic costs of his marvellous biography of Picasso, John Richardson had to create his own foundation – even then, the third volume was delayed and he made no money from it. Tracking down copyright holders and getting answers from them can be a laborious task. But until the subject has been dead for 70 years (it used be a mere 50), there's no getting round it – even if, as Michael Holroyd says, this means enriching the dead at the expense of the living.

The Society of Authors and the Publishers Association have guidelines on what they call "fair dealing": with prose, a single extract of up to 400 words or a series of extracts of up to 800 words shouldn't require permission; with poetry, up to 40 lines, provided that doesn't exceed a quarter of the poem's length. But these guidelines are only for the purposes of critical commentary, not for an imaginative work, and as far as the music industry is concerned even a line, no matter how banal, constitutes a "substantial part" of a song. Quoting six words and five syllables from "You've Lost that Lovin' Feelin'" cost me £300.

It would be hypocritical to get too indignant. Poets and novelists also have a living to make, and if someone wants to anthologise us we expect our agents or publishers to charge permission fees, however modest. At least we used to. The internet is gradually changing all that. Now that consumers expect owt for nowt, the temptation is to put stuff in online journals or on your own website, free of charge. It's arguably a more congenial form of self-promotion than Facebook or Twitter. And, since literature is about breaking down barriers, who wants to be associated with a paywall?

In the long run, such liberality will be self-defeating, though: no fee, no win. If authors aren't paid for their words, writing will become a gentlemanly profession again, with only the rich having the wherewithal to do it full-time. Techno-optimists don't see it that way. For them blogging and internet publishing are democratising – a return to a pre-capitalist world of commonality, the online equivalent of oral culture. But the idea that artists have property rights didn't arrive with the Enclosure Act. It's at least as old as ancient Greece. And though breaching copyright is less of an offence than plagiarism, both are a form of theft – a failure to credit the author for his or her creativity.

So though it pained me to fork out £1,000 for 11 words of "I Shot the Sheriff" – that's more than £90 a word – I mustn't begrudge the Bob Marley estate. But next time I need songs I'll make them up myself. Or do as the narrator does in my new novel, when he hears U2 coming from his housemate's bedroom – refrain from quoting even a syllable of the lyrics.