Shortly after nine in the morning of April 25 1816, the poet George Gordon Lord Byron left England for the continent. On board the Dover packet, he watched the white cliffs receding, knowing in his heart he would not be returning. He departed in a stormy atmosphere of scandal, separated from his wife after just a year of marriage. Did he leave of his own free will or was he forced?

Byron's loyal friends insisted he left England voluntarily: "There was not the slightest necessity even in appearance for his going abroad," wrote the stalwart John Cam Hobhouse. The facts of Byron's exile have been glossed over by most of his biographers. Proliferating accusations of cruelty, adultery and Byron's incest with his half-sister Augusta have been taken as explanation enough - although incest was punishable by the ecclesiastical courts but not a criminal offence. It was the much more serious allegation of sodomy, a crime bearing the death sentence in homophobic early 19th-century England, that led to Byron being virtually driven out.

He was to be forever haunted by the scenes of hostility during his final weeks in England: "I was advised not to go to the theatres, lest I should be hissed, nor to my duty in parliament, lest I should be insulted by the way; even on the day of my departure my most intimate friend told me afterwards that he was under apprehension of violence from the people who might be assembled at the door of the carriage." It was feared he was in danger of lynching by the mob. In the Dover hotel some women went so far as to disguise themselves as chambermaids to get a closer look at him, as if he had become an exhibit in a freak show. The violence of this public reaction resembles the hatred that, 80 years later, was hurled at Oscar Wilde.

Byron's ignominy was the more bitter because it followed a phase of unparalleled success. In 1812, the publication of the first two parts of his philosophical travelogue Childe Harold's Pilgrimage brought instant accolades. Byron described how he awoke one morning and found himself famous. Four exotic eastern tales, based on his own travels in Turkey, Albania and Greece, confirmed his popularity. In 1814, 10,000 copies of The Corsair were sold on the day of publication - "a thing perfectly unprecedented" beamed his publisher John Murray. In his sudden fall from grace Byron was a victim of the hysterical opprobrium that often succeeds extreme celebrity, a cycle wearyingly familiar to us now.

The young Byron had revelled in his success. Fame at first had been sweet to the only child raised by his mother in relative obscurity in Aberdeen. His absentee father, a glamorous but dissolute ex-army captain known to his cronies as "Mad Jack" Byron, had died in penury in France when his son was only three, a suspected suicide. At 10, Byron had succeeded his great uncle, the fifth lord, and inherited the vast Gothic pile of Newstead Abbey in Nottinghamshire. But even this was a mixed blessing: the building was dilapidated; there were no funds for its upkeep. Byron, acutely conscious of status, was aware that compared with, say, the future Duke of Devonshire, his school fellow at Harrow, he could be regarded as only a minor peer.

Byron had been born with the deformity his contemporaries referred to as a club-foot, and his hunger for approbation had been heightened by this physical disability. Modern medical experts have preferred to view Byron's malformation as a dysplasia, a failure of a bodypart to form properly. Byron's purpose-made boots, still in the archive collection at John Murray, were built up to counteract his abnormally small and inward-turning right foot and padded to disguise his grotesquely thin calf. His foot had attracted cruel derision from the other boys at Harrow, later recalled by Byron with a shudder.

"The Morning Post in particular has found out that I am a sort of Richard the third - deformed in mind & body - the last piece of information is not very new to a man who passed five years at a public school."

Byron's attraction to adolescent boys had first become evident at Harrow, where he referred to his entourage of adoring younger pupils as his Theban band. At Cambridge, Byron fell in with a sophisticated group of like-minded friends fascinated by the theory and practice of sodomy. Their hero was William Beckford, author of the libidinous eastern dream novel The Caliph Vathek, who had been forced to flee the country rather than face possible criminal charges related to a homosexual scandal. They called themselves by the codename Methodists. In autumn 1805, when he was 17, Byron met and fell in love with John Edleston, a Trinity College chorister, and wrote some of his most beautiful lyrics of lament to his "musical protégé", using the deceptive female name of Thyrza, after Edleston died young.

It is clear from Byron's correspondence of this period that one of his main motives in setting out on extended travels in 1809-10 was his hope of homosexual experience. In Greece and Turkey, sex with boys was more or less accepted as the norm and he found willing partners. There was Eusthathius Georgiou, the volatile Greek boy with "ambrosial curls" whose parasol, carried to protect his complexion from the sun, made Byron's valet cringe. There was the Franco-Greek Nicolo Giraud, with his limpid eyes, who taught Byron Italian in Athens, taking a whole day to conjugate the verb "to embrace". By the end of Byron's stay in Greece he was boasting to his Methodist friends that he had achievedmore than 200 "pl and opt Cs", their code for unlimited sexual intercourse, taken from Petronius's Satyricon "coitum plenum et optabilem".

When Byron arrived back in England in summer 1811, prejudice against homosexuals was on the increase after a police raid on the White Swan tavern in Vere Street, London. Of the men charged with "assault with the intention to commit sodomy", six were sentenced to be pilloried in the Haymarket, where they were pelted with mud and excrement by a savage crowd. Byron was lectured about the need for caution by Hobhouse, who had already persuaded him to burn his early journal, which presumably included an account of his love for the choirboy Edleston. Byron later said the loss of this manuscript was "irreparable".

From 1812 to 1815, Byron's "curl'd darling" years of literary fame, he was swept up in the whirl of London social activity. For its readers in that period of moral and political uncertainty, two decades after the upheavals of the French revolution, the subversive energy of Byron's Childe Harold had struck an extraordinary chord. Its success was entwined with the mysterious persona of its author, the 24-year-old Lord Byron, the handsome, lame young aristocrat recently returned from the east. When Lord Holland, at a soirée at Holland House, bore in a metal vessel looking like an incense burner, exclaiming to Thomas Campbell "Here is some incense for you," the older poet replied a little huffily, "Carry it to Lord Byron, he is used to it."

Byron acquired an almost royal charisma in the period he would later refer to as his "reign". All doors were open to him: he frequented the great Whig houses of the period, mingling with the Hollands, the Melbournes, the Jerseys. He was lionised by the leading London hostesses, whose eagerness was intensified by Byron's remoteness, the "sort of moonlight paleness" manifested in some of his most famous portraits. His translucent white face and high domed forehead was compared by one of his contemporaries to an alabaster vase lit up from within.

Byron's admirers were by no means only aristocratic ladies of a certain age. As women later swarmed around the also bisexual Rudolph Valentino, fans from all social classes pursued Byron: young and old, uneducated and bluestocking, unloading their secret fantasies, excited and emboldened by Byron's poetry to seek out its originator. Hundreds of these women wrote to Byron, often anonymously, furtively, entreating him for a sample of his handwriting, signed copies of his work, a curl of his dark auburn hair, a clandestine meeting, "an occasional place in your Lordship's thoughts". Many of these frantic letters are still in the Byron archives. Why did he hoard them? Such proof of his power over women freed him from his consciousness of being the derided cripple and distracted him from the homosexual instincts he was, at this period, trying to repress.

Byron worked at his image. He disciplined his tendency to plumpness by vigorous dieting and the use of purgatives. He controlled the uses of his portrait in marketing his poetry, instructing his publisher John Murray to destroy any version of which he disapproved. Theatrically and gleefully, Byron camped it up, hovering malevolently on the edges of the ballroom, sneering at the fashionable waltzers, in the guise of the glamorous malcontent. He made himself available and then retreated. His tendency to depression made him prone to the mood swings that still afflict celebrities, dependent on the signs of adulation yet detesting them.

With false Ambition what had I to do?

Little with love, and least of all with fame!

And yet they came unsought and with me grew,

And made me all which they can make - a Name.

Byron wrote these lines in 1816. The pitiless satirist saw the sardonic humour of his casting as the heartthrob of his age.

His sexual conflicts impelled Byron into wild behaviour. His relationships with women needed the extreme, the risqué, to fan them into life. Cross-dressing was a feature of these complicated sex games. The arousing innuendoes of his summer with "blue-eyed Caroline", a prostitute passed off in Brighton as Byron's brother Gordon, were recreated on a more sophisticated level in his perilously public affair with Lady Caroline Lamb. The gamine, crop-haired Caro was already a page-fancier and needed no encouragement to dress in page's uniform for Byron's delectation, their increasingly hysterical liaison being sustained by a creaky assortment of Gothic props. The incestuous relationship with his half-sister Augusta allowed Byron the new frisson of the familiar yet outré. He was her "baby Byron". She spoke his childhood language. In a sense Augusta was the mirror image of himself.

It was the incomparably versatile Lady Caroline who doomed him. Early in 1815 Byron had made an unenthusiastic marriage to Caro's husband's cousin, Annabella Milbanke. Caro had predicted that he would "never be able to pull with a woman who went to church punctually, understood statistics and had a bad figure". The claustrophobia of conventional married life in Piccadilly Terrace prompted Byron to behave badly with a thoroughness only he could have achieved, flaunting his relations with Augusta, throwing out dark hints of his homosexual past and (in his favourite role of the stage villain) shooting the tops off his soda-water bottles while his wife was in labour in the room upstairs.

On January 15 1816 Annabella and their infant daughter left London, taking refuge at her parents' country house in Leicestershire. Three weeks later her father, Sir Ralph Milbanke, wrote formally to Byron to request a separation. Rumours of marital violence, adultery with actresses and his incest with his sister began to circulate. In early February the "villainous intriguante" Lady Caroline began spreading her own version of these stories, perpetrating the worst possible revenge of the woman scorned. "Accused B of - poor fellow, the plot thickens against him," reported Hobhouse. The dash in his diary stands for sodomy. Byron's sexual predilections, up to then known only to his confidential inner circle, were becoming public property. On February 12, Hobhouse brought Byron the alarming news of what he had been hearing "in the streets" that day.

Byron was "astounded indeed". He understood just how serious these allegations were in the repressive sexual climate of the day, becoming "dreadfully agitated" and threatening to blow his brains out. A few days later a panicky Augusta wrote to Lady Byron to let her know of "reports abroad of a nature too horrible to repeat... Every other sinks into nothing besides this MOST horrid one". She quoted Byron as admitting, on the previous evening: "Even to have such a thing said is utter destruction & ruin to a man from which he can never recover." In a postscript to her sister-in-law she added, "I think you will not misunderstand to what I allude."

Suspicions of marital sodomy now entered the equation, evidently convincing to Byron's former patron Lord Holland, who told Hobhouse that Byron had "tried to -" Lady Byron. The possibility of anal intercourse between the Byrons was to paralyse some of Byron's best known 20th-century biographers. "I fear I cannot complete that sentence," wrote Harold Nicolson in 1924, while in 1974 Doris Langley Moore ridiculed the idea that Annabella could ever have submitted "responsively to a perversion that was then a felony - and which would still, I fancy, repel any woman of delicacy".

Having intended to defend himself in court, denying responsibility for the ending of his marriage, Byron was now persuaded that this would be unwise, since evidence of "something horrid" might be brought against him. The separation was negotiated privately. The curl'd darling had now become a social outcast. Early in April, he and Augusta were cold-shouldered when they appeared together at a London soirée given by Lady Jersey.

Byron's humiliations were by no means at an end with his crossing of the Channel later in the month. "I withdrew," he wrote, "but this was not enough - In other countries - in Switzerland - in the shadow of the Alps - and by the blue depths of the Lakes I was pursued and breathed upon by the same blight. - I crossed the Mountains - but it was the same - so I went - a little farther, and settled myself by the waves of the Adriatic - like the Stag at bay who betakes him to the waters."

In Geneva, English tourists spied on Byron across the lake through hired telescopes. Conversely, encountering Byron on the rooftop of St Peter's in Rome, Lady Liddell gave instructions to her daughter to avert her eyes: "Don't look at him, he is dangerous to look at." The ordeal of what he called his "ostracism" confirmed Byron in his hatred of the English. Only in England, he argued, did pre-eminence so inevitably and cruelly give way to "envy, jealousy, and all uncharitableness". His sentiments were echoed by Macaulay in an 1831 essay on Byron: "We know no spectacle so ridiculous as the British public in one of its periodic fits of morality."

But anger was also a stimulant. "It is odd, but agitation or contest of any kind gives a rebound to my spirits," Byron once remarked. His fury and his grief at what he saw as the vindictive injustice of his banishment impelled him into a new phase of creative energy. He had started on the third canto of Childe Harold while still on board ship, not long after leaving Dover. The years of his exile, as he shifted his ramshackle households from Venice to Ravenna to Pisa to Genoa, were enormously productive. He completed Childe Harold, embarked on Don Juan, wrote the anti-monarchical satire A Vision of Judgement, works we now regard as the quintessential Byron, morally trenchant, hilariously funny, revealing his great empathy, the depth of his humanity. They show a triumphant rebound from his despair.

The bitter experience of rejection made Byron more inventively reckless in his writing. When John Murray and London friends remonstrated with him over controversial politics and sexual explicitness - " Don Juan is exquisite - it must be cut for syphilis" - Byron was defiant in defending his authorial integrity. "I will not give way to all the Cant of Christendom. I have been cloyed with applause and sickened with abuse." With the publication of Cain, denounced as blasphemous from pulpits all over England and its author described as "a cool, unconcerned fiend", the disagreements with Murray escalated. Byron moved to the more radical publisher John Hunt.

A further effect of Byron's exile was the seriousness of his new political involvements. Back in England, a hopeful young recruit to the Whig party, he had taken his seat in the House of Lords. His debut speech in 1812, in opposition to the Tory frame-breaking bill, had been a passionate plea for sympathy for the Nottinghamshire stocking weavers whose livelihood was jeopardised by increasing mechanisation of the trade. But in those days Byron had been easily distracted, likely to leave the debating chamber if a society ball was in the offing. Now, chastened by experience, conscious of his own ambivalent social position, he allied himself wholeheartedly with Europe's oppressed minorities.

His first foray into resistance politics was as a member of the Ravenna Carbonari, one of a network of insurrectionist groups in the Romagna aiming to cast off Austrian domination. Byron controlled his own troop, the Cacciatori Americani, originally a troop of forest fighters. He saw the freeing of Italy as "a grand object, the very poetry of politics". After the shame of exile, his acceptance into the camaraderie of revolution seemed an exoneration.

Byron's involvement in the Greek war of independence has sometimes been viewed as the culminating episode in his yearning for celebrity, and while it is true that his role as agent of the London Greek committee in the war against the occupying Turks allowed him to fulfil his boyhood dream of emulating the Emperor Napoleon, ordering resplendent uniforms and plumed Homeric helmets, anyone who needs to be convinced of his firmness and good judgment in the conduct of the war should read his correspondence of this period. In embattled western Greece he found a situation as complex and explosive as that recently prevailing in Afghanistan. With admirable coolness he weighed up the pros and cons of the clamorous tribal chiefs and rival warlords, all eager for a handout. His unflamboyant death at 36, not in action but from fever, created for Byron another kind of fame: the respect that attached to the writer who had harnessed his talents to a humanitarian cause.

The news was slow to reach England. Despatches from Corfu, though sent express via Ancona, did not arrive in London until May 13 1824, almost a month after Byron's death. His friends' initial shock and grief soon gave way to panic in a country where, as Byron so memorably put it, "the Cant is so much stronger than Cunt". Hobhouse noted in his diary his determination "to lose no time in doing my duty by preserving all that was left to me of my dear friend - his fame".

The first casualty was Byron's memoirs, the self-justifying and reputedly erotic story of his life he had written while in Italy and given to his impecunious friend Tom Moore, to be sold to John Murray for posthumous publication. Murray had gladly paid Moore £2,000. Hobhouse had not read the memoirs, but he was taking no chances. He may have feared that a recurrence of the scandals relating to sodomy and incest would devolve on the now important public figure of John Cam Hobhouse, MP for Westminster. He was determined the memoirs must be destroyed. Hobhouse bullied and implored until, in the most famous sacrificial scene in literary history, Byron's manuscript went up in flames in the drawing-room grate of Murray's premises in Albemarle Street, watched by a balefully self-righteous publisher and an agonised Moore.

Hobhouse, as executor, followed through this triumph by suppressing two love poems written by Byron to his Greek page, Lukas Chalandritsanos, during his final weeks in Missolonghi and returned to England with his other papers. To one of them Hobhouse appended the obfuscating words, "A note attached to these verses by Lord Byron states they were addressed to nobody and were a mere poetical scherzo." It is likely the zealous Hobhouse tore to pieces a further Lukas poem.

The confusion that greeted Byron's corpse when it finally reached England at the end of June 1824 reminds one irresistibly of the disarray that followed the return from Paris of Diana, Princess of Wales. What to do with the body? Byron's friends and supporters had envisaged a hero's welcome for him, a state funeral in Westminster Abbey, a prominent place in Poets' Corner. But the British establishment was not so forgiving. Dr Ireland, Dean of Westminster, suggested that instead the best thing to be done was "to carry away the body, & say as little about it as possible".

However, the spontaneous reaction of the public took the authorities by surprise. The river banks were crowded with spectators as the undertaker's barge brought Byron's coffin up the Thames late in the afternoon of July 5. For the following week his body lay on view at 20 Great George Street in Westminster, a house his executors had hired for the purpose. The room in which the coffin lay was hung in black, with the Byron arms daubed roughly on a deal board. For two days, July 10 and 11, the public was admitted by ticket. In contrast to the mood of official disapproval there were now displays of near-hysterical emotion. London police sergeants had to be called in and a wooden frame erected round the coffin. It was reported that "Of the crowded visitors the number of ladies was exceedingly great".

The working-class poet John Clare watched Byron's funeral procession as it made its way down a thronging Oxford Street. He was immensely moved, writing later in his journal: "The common people felt his merits and his power and the common people of a country are the best feelings of a prophesy of futurity."

Byron's reinstatement has been a long time coming. One of the first signs of official recognition was in 1959 when the Queen Mother unveiled a memorial statue of Lord Byron at the Villa Borghese in Rome. The dowager queen was partial to amusing queers. But it is doubtful if anybody told her Byron's real history, in those discreet days before a 1967 change in English law decriminalised homosexual acts between consenting adults, following the recommendations of the Wolfenden report.

Leslie Marchand, working on his monumental three-volume biography of Byron in the same period, recalled how he was under instructions from Sir John Murray, the then head of the firm, to censor his account of Byron's recurring love for adolescent boys, despite the fact that the evidence was there. A precise account of Byron's sexual history and its reverberations in his marvellous, challenging, insinuating poetry, drawing on the whole rich resources of the Murray archive, is only now becoming possible.

· Fiona MacCarthy's Byron: Life and Legend is published by John Murray, price £25.