Just three months ago, at the end of February, I was sitting in a bar in the Chicago Hilton, discussing Ray Bradbury. I was staying at the Hilton, and in a moment Bradburian in its weirdness, I had been put into the suite where President Obama saw on TV that he had just won the US presidential election. On that occasion the immense, many-roomed suite must have been full – of family, of security folks, of political staffers – but I was in it all alone, and it was not the best place to be while dwelling on things Bradburian. It was too easy to imagine that there was someone in the next room. Worse, that someone might be my evil twin, or myself at a different age, or it might contain a mirror in which I would cast no reflection. It took some self-control not to go in there and look.

In February, however, the Chicago Hilton was not crawling with secret servicemen talking into their sleeves, but with 4,000 writers, would-be writers, students of writing, and teachers of writing, all of whom were attending the conference of the Association of Writers and Writing Programs where I was to give the keynote address, and every single one of whom would have known who Ray Bradbury was.

In the Hilton bar with me was Bradbury's biographer, Sam Weller. It was the first time I'd met him, in person that is, though I felt I already knew him. He'd contacted me on Twitter – this is a 21st-century story – to see if I'd like to contribute to a tribute volume, edited by himself and by veteran horror writer Mort Castle. The brief: to write a short story in Bradburyesque mode, whatever that might be; or whatever those might be, since Bradbury's work came in many modes. I enthusiastically agreed to take a crack at it, and so did 25 other writers, including Neil Gaiman, Alice Hoffman, Harlan Ellison, Dave Eggers, Joe Hill, Audrey Niffenegger, and Charles Yu. Each one of us had responded because we'd been influenced in some way by Ray Bradbury.

What Sam and I were discussing was the launch of the collection, which was to be published by HarperCollins, and was to be called Shadow Show – from the 1962 Bradbury novel, Something Wicked This Way Comes. Ray himself had written an introduction, and it was hoped that he could be present at the grand celebration that was to take place at ComicCon, the vast gathering of graphic artists, comics writers and their fans, plus related enterprises and genres, that was slated for San Diego in mid-July. Five of us were going to do a Bradbury panel there: Sam, Mort Castle, Joe Hill, me and Ray himself.

But Ray had been feeling a little frail, said Sam; it was possible he might not make it. In that case, the four of us would do the panel, and Sam and I would visit Ray in his home, webcast him to the world, connect him with his fans, and ask him to sign some covers of the book for them on the Fanado.com website I'd been involved in developing. Ray was keen to do it, said Sam, despite his qualified distrust of the internet. His enthusiasm for his many devoted readers and his fellow writers never waned, and if using the questionable internet was the method of last resort, then that is what he would do.

I was greatly looking forward to meeting a writer who had been so much a part of my own early reading, especially the delicious, clandestine reading done avidly in lieu of homework, and the compulsive reading done at night with a flashlight when I ought to have been sleeping. Stories read with such enthusiasm at such a young age are not so much read as inhaled. They sink all the way in and all the way down, and they stay with you.

But now Ray Bradbury has died. He was 91, but still – as with everyone who has always been in your life and is then not there any more – his death seems impossible. People don't die as such in his work; or they don't die in the ordinary way. Sometimes they melt – the Martian in the story of that name dissolves, like the Wicked Witch of the West in The Wonderful Wizard of Oz, one of Bradbury's influences. Sometimes they are done to death by aliens, as in The Martian Chronicles story, "The Third Expedition". Sometimes they are hunted down by mechanical hounds for the crime of reading books, as in Fahrenheit 451. Sometimes people don't entirely die: revenants and vampires are not unknown in Bradbury's work. But Bradbury's people seldom just expire.

Any writer who delves as deeply into "horror" writing as Bradbury did has a complex relationship with mortality, and it's not surprising to learn that Ray Bradbury as a child was worried that he would die at any moment, as he tells us in "Take Me Home", a sidebar in this June's New Yorker Science Fiction issue. "When I look back now," he says – in what, ironically, was going to be his last published piece – "I realise what a trial I must have been to my friends and relatives. It was one frenzy after one enthusiasm after one hysteria after another. I was always yelling and running somewhere, because I was afraid life was going to be over that very afternoon."

But the flip side of the mortality coin is immortality, and that interested him as well. At the age of 12 – as he tells us on his website – he had a definitive encounter with a stage magician called Mr Electrico. This was in the age of travelling circuses and the like, and Mr Electrico had a unique act: he sat in an electrified chair, thus in turn electrifying a sword he held, with which he in turn electrified the spectators, making their hair stand on end and sparks come out of their ears. He electrified young Bradbury in this manner, while shouting, "Live Forever!" The child had to go to a funeral the next day, a close encounter with death that led him to seek out Mr Electrico once more to find out how this living forever thing was to be done. The old carney showed him around what used to be called the freak show – complete with a tattooed man who was later to morph into the Illustrated Man – and then told him that he, Ray, contained the soul of Mr Electrico's best friend, who had died in the first world war. You can see how all this would have made an impression. Right after his baptism by electricity at the hands of Mr Electrico, Bradbury started writing; nor did he stop until his own death.

How do you live forever? Through other people, it seemed: those whose souls turned up in your body. And through other voices, the voices that spoke through you. And through your written words, the code for those voices. At the end of Fahrenheit 451, the hero finds – in a world of destroyed books – a group of people who have become the vanished books by memorising them: a perfect embodiment for the knot of mysteries presented to young Ray by Mr Electrico.

This evening – in the middle of writing this eulogy, for that is what it is – I had to break off in order to attend a poetry event. At the party afterwards, I told a writer friend that Bradbury had died. "He was the first writer I read all of," he said. "When I was 12 or 13. I read every single book – I sought them out. I read them cover to cover." I said I thought that a lot of writers – and a lot of readers – had most likely had the same experience. And that they would be writers and readers of the most diverse kinds – poets and prose writers, all ages, all levels of brow, from low to high.

What accounts for Bradbury's reach – his scope, his influence? And – dreaded question, but one that critics and interviewers are always asking – where would you locate him on the map of literature?

My own view is that, in his best work, Bradbury sinks a taproot right down into the deep, dark, Gothic core of America. It's no accident that he was descended from Mary Bradbury, convicted as a witch in 1692, during the notorious Salem witchcraft trials, for, among other things, assuming the form of a blue boar. (She was not hanged, as the execution was delayed until the craze was over.) The Salem trials are a seminal trope in American history, one that has repeated itself over and over in various forms – both literary and political – throughout the years. At its heart is the notion of the doubleness of life: you are not who you are, but have a secret and probably evil twin; more importantly, the neighbours are not who you think they are. They might be witches, in the 17th century, or people who will falsely accuse you of being a witch; or traitors, in the 18th century, at the time of the revolution; or communists, in the 20th; or people who will stone you to death, in Shirley Jackson's "The Lottery"; or terrorists, in the 21st. In the 19th century, Nathaniel Hawthorne – himself connected to the Salem trials through his ancestor, a hanging judge – wrote "Young Goodman Brown", a perfect expression of this theme. (Puritan Brown discovers, or perhaps dreams, that his godly neighbours are all members of a satanic coven.) Henry James has his own version: "The Jolly Corner", in which a Europeanised American encounters the ghost of himself as he would have been had he remained in America, a sort of rich monster.

Vladimir Nabokov said, in Pnin, that Salvador Dalì "is really Norman Rockwell's twin brother kidnapped by Gypsies in babyhood". But Bradbury was also a twin brother of Rockwell, kidnapped in babyhood by some darker force – Edgar Allan Poe, perhaps, whom he read avidly at the age of eight. Poe's "William Wilson" opposes two twinned selves, and Bradbury can almost be said to have acted them out: the bright self, all sunshine and front porches and lemonade; and the dark one, the one who could imagine two children luring their own parents to death in "The Veldt". Two of the Martian Chronicles stories twist these skeins together admirably. In "The Martian", an American family has moved to Mars to try to create a new life after the death of their son. But the dead son shows up, just as he used to be, and father, mother and son settle into a Rockwell normality. The son is really a Martian, a shapechanger who reflects the desires of others; and the story spirals down into tragedy, with the equivalent of a mob lynching at the end.

In "The Third Expedition" – called, originally, "Mars is Heaven" – space explorers from Earth find that the mellow, prewar hometown of their childhood is now on Mars, complete with old friends and family members, including dead ones. What a fine reunion they all have, until it turns out that the town and its inhabitants are mirages, devised by the Martians to lull the invaders – perceived by the Martians as harmful – so that they can be exterminated. Who can you trust? Dang near nobody. Or dang near nobody who claims a Rockwellian normality, which is bound to be a façade.

But nostalgia for the same Rockwellian normality is very real in Bradbury's work, the detail lovingly rendered. He was born in 1920 in Waukegan, Illinois, and it is this town and this time – the 20s and 30s of his youth – that appears again and again in his work, sometimes on Earth, sometimes on Mars. You can't go home again, said Thomas Wolfe – another American nostalgist – but you can get back the past by writing about it, maybe, as Wolfe and Bradbury both did. However, the charm lasts only until midnight strikes and things fall apart. The shadow of the black-shrouded clock from Poe's "Masque of the Red Death" is never far from Bradbury's world, even at its sunniest: time is the enemy.

As a writer, Bradbury grew up in the "golden age" of science fiction – usually thought of as the 30s – and built his career, initially, on the platform that existed then and for several decades thereafter: an extensive popular-magazine market for short fiction. Though he would end by publishing in the respected New Yorker, he began in 1938 by publishing in an amateur fan magazine, then his own magazine, Futura Fantasies; then he published in the pulps, including Super Science Stories and Weird Tales. You could make a living at that, then, if you wrote a lot, and Bradbury did. He wrote every day, and once vowed to write a story a week – a feat he accomplished. His income was helped along by adaptations for the comics, then by screen and TV adaptations. He worked his way up to the glossies, including Playboy and Esquire. Writing was both his vocation – he was called to it, and wrote intuitively – and his career, by which he supported himself and his family; and he was proud of both of these aspects.

He ducked classification and genre corrals as much as he could: as far as he was concerned he was a tale-teller, a writer of fiction, and as far as he was concerned the tales and the fiction did not need to have labels.

The term "science fiction" made him nervous: he did not want to be shut up in a box. And he, in his turn, made "science fiction" purists nervous, as well he might. Mars in his hands, for instance, is not a place described with scientific accuracy or even much consistency, but a state of mind; he recycles it for whatever he needs at the moment. Space ships are not miracles of technology, but psychic conveyances, serving the same purpose as Dorothy's whirlwind-borne house in The Wonderful Wizard of Oz, or the trance of the traditional shaman: they get you to the Otherworld.

Ray Bradbury saw his writing as a way of living on after his death, and it will certainly perform that service. But then there's Bradbury as a person. All who knew Bradbury testify to his generosity towards others. His imagination had a dark side, and he used that dark twin and its nightmares in his work; but to the waking world he presented a combination of eager, wonder-filled boy and kindly uncle, and that was just as real. In an age of writing classes, he was self-taught; in an age of spin, his was an authentic voice, straight from the heartland; in an age of groomed images, he was a natural.