As they plough through their GCSE revision, UK students planning to take politics A-level in the autumn can comfort themselves with this thought: come September, they will be studying one thinker who does not belong in the dusty archives of ancient political theory but is achingly on trend. For the curriculum includes a new addition: the work of Ayn Rand.

It is a timely decision because Rand, who died in 1982 and was alternately ridiculed and revered throughout her lifetime, is having a moment. Long the poster girl of a particularly hardcore brand of free-market fundamentalism – the advocate of a philosophy she called “the virtue of selfishness” – Rand has always had acolytes in the conservative political classes. The Republican speaker of the US House of Representatives, Paul Ryan, is so committed a Randian, he was famous for giving every new member of his staff a copy of Rand’s gargantuan novel, Atlas Shrugged (along with Freidrich Hayek’s Road to Serfdom). The story, oft-repeated, that his colleague in the US Senate, Rand Paul, owes his first name to his father Ron’s adulation of Ayn (it rhymes with “mine”) turns out to be apocryphal, but Paul describes himself as a fan all the same.

Not to be left out, Britain’s small-staters have devised their own ways of worshipping at the shrine of Ayn. Communities secretary Sajid Javid reads the courtroom scene in Rand’s The Fountainhead twice a year and has done so throughout his adult life. As a student, he read that bit aloud to the woman who is now his wife, though the exercise proved to be a one-off. As Javid recently confessed to the Spectator, she told him that if he tried that again, he would get dumped. Meanwhile, Daniel Hannan, the Tory MEP many see as the intellectual architect of Brexit, keeps a photograph of Rand on his Brussels desk.

Sajid Javid: the communities secretary boasts of reading Rand’s novel The Fountainhead twice a year throughout his adult life. Photograph: Carl Court/Getty Images

So the devotion of Toryboys, in both their UK and US incarnations, is not new. But Rand’s philosophy of rugged, uncompromising individualism – of contempt for both the state and the lazy, conformist world of the corporate boardroom — now has a follower in the White House. What is more, there is a new legion of devotees, one whose influence over our daily lives dwarfs that of most politicians. They are the titans of tech.

So who is this new entrant on the A-level syllabus, the woman hailed by one biographer as the goddess of the market? Born Alisa Zinov’yevna Rosenbaum in 1905 in St Petersburg, Russia, she saw her father impoverished and her family driven to the brink of starvation by the Soviet revolution, an experience that forged her contempt for all notions of the collective good and, especially, for the state as a mechanism for ensuring equality.

An obsessive cinemagoer, she fled to the US in 1926, swiftly making her way to Hollywood. She paid her way through a series of odd jobs, including a stint in the costume department of RKO Pictures, and landed a role as an extra in Cecil B DeMille’s The King of Kings. But writing was her passion. Broadway plays and movie scripts followed, until the breakthrough came with a novel: The Fountainhead.

Published in 1943, it tells the story of Howard Roark, an architect dedicated to the pursuit of his own vision – a man who would rather see his buildings dynamited than compromise on the perfection of his designs. All around him are mediocrities, representing either the dead hand of the state, bureaucrats serving some notional collective good, or “second handers” – corporate parasites who profit from the work and vision of others.

Then, in 1957, came Atlas Shrugged, whose Penguin Classic edition stretches to 1,184 pages. Here Roark gives way to John Galt, another capitalist genius, who leads a strike by the “men of talent” and drive, thereby depriving society of “the motor of the world”.

In those novels, and in the essays and lectures she turned to afterwards, Rand expounded – at great and repetitive length – her philosophy, soon to be taught to A-level students alongside Hobbes and Burke. Objectivism, she called it, distilled by her as the belief that “man exists for his own sake, that the pursuit of his own happiness is his highest moral purpose, that he must not sacrifice himself to others, nor sacrifice others to himself”. She had lots to say about everything else too – an avowed atheist, she was dismissive of any knowledge that was not rooted in what you could see in front of your eyes. She had no patience for “instinct” or “‘intuition’ … or any form of ‘just knowing’”.

Kent Smith and Gary Cooper in the 1949 film of Rand’s novel The Fountainhead. Photograph: Allstar/Warner Bros

The Fountainhead was serially rejected and published to ambivalent reviews, but it became a word-of-mouth hit. Over the coming years, a cult following arose around Rand (as well as something very close to an actual cult among her inner circle, known, no doubt ironically, as the Collective). Her works struck a chord with a particular kind of reader: adolescent, male and thirsting for an ideology brimming with moral certainty. As the New Yorker said in 2009: “Most readers make their first and last trip to Galt’s Gulch – the hidden-valley paradise of born-again capitalists featured in Atlas Shrugged, its solid-gold dollar sign standing like a maypole – sometime between leaving Middle-earth and packing for college.”

But for some, objectivism stuck. Perhaps her most significant early follower was Alan Greenspan, later to serve as chairman of the US Federal Reserve for 19 years. In the 1950s, Greenspan was one of the Collective, and he would be among the mourners at her funeral in 1982, where one floral wreath was fashioned into that same 6ft dollar sign, now understood to be the logo of Randism.

Greenspan is the link between the original Rand cult and what we might think of as the second age of Rand: the Thatcher-Reagan years, when the laissez-faire, free-market philosophy went from the crankish obsession of rightwing economists to the governing credo of Anglo-American capitalism. Greenspan, appointed as the US’s central banker by Ronald Reagan in 1987, firmly believed that market forces, unimpeded, were the best mechanism for the management and distribution of a society’s resources. That view – which Greenspan would rethink after the crash of 2008-9 – rested on the assumption that economic actors behave rationally, always acting in their own self-interest. The primacy of self-interest, rather than altruism or any other nonmaterial motive, was, of course, a central tenet of Randian thought.

Put more baldly, the reason why Republicans and British Conservatives started giving each other copies of Atlas Shrugged in the 80s was that Rand seemed to grant intellectual heft to the prevailing ethos of the time. Her insistence on the “morality of rational self-interest” and “the virtue of selfishness” sounded like an upmarket version of the slogan, derived from Oliver Stone’s Wall Street, that defined the era: greed is good. Rand was Gordon Gekko with A-levels.

Alan Greenspan: the former chairman of the Federal Reserve was a longtime member of Rand’s inner circle. Photograph: Bloomberg/Bloomberg via Getty Images

The third age of Rand came with the financial crash and the presidency of Barack Obama that followed. Spooked by the fear that Obama was bent on expanding the state, the Tea Party and others returned to the old-time religion of rolling back government. As Rand biographer Jennifer Burns told Quartz: “In moments of liberal dominance, people turn to her because they see Atlas Shrugged as a prophecy as to what’s going to happen if the government is given too much power.”

In that context, it seemed only natural that one of the success stories of the 2012 presidential campaign was a bid for the Republican nomination by the ultra-libertarian and Rand-admiring Texas congressman Ron Paul, father of Senator Rand Paul, whose insurgent movement was a forerunner for much of what would unfold in 2016. Paul offered a radical downsizing of the federal government. Like Ayn Rand, he believed the state’s role should be limited to providing an army, a police force, a court system – and not much else.

But Rand presented a problem for US Republicans otherwise keen to embrace her legacy. She was a devout atheist, withering in her disdain for the nonobjectivist mysticism of religion. Yet, inside the Republican party, those with libertarian leanings have only been able to make headway by riding pillion with social conservatives and, specifically, white evangelical Christians. The dilemma was embodied by Paul Ryan, named as Mitt Romney’s running mate in the 2012 contest. Ryan moved fast to play down the Rand influence, preferring to say his philosophy was inspired by St Thomas Aquinas.

What of the current moment, shaping up to be the fourth age of Rand? The Randian politicians are still in place: Ryan is now boosted by a cabinet crammed with objectivists. Secretary of state Rex Tillerson named Atlas Shrugged as his favourite book, while Donald Trump’s first choice (later dropped) as labor secretary, Andy Puzder, is the CEO of a restaurant chain owned by Roark Capital Group – a private equity fund named after the hero of The Fountainhead. CIA director Mike Pompeo is another conservative who says Atlas Shrugged “really had an impact on me”.

Of course, this merely makes these men like their boss. Trump is notoriously no reader of books: he has only ever spoken about liking three works of fiction. But, inevitably, one of them was The Fountainhead. “It relates to business, beauty, life and inner emotions. That book relates to ... everything,” he said last year.

Rand scholars find this affinity of Trump’s puzzling. Not least because Trump’s offer to the electorate in 2016 was not a promise of an unfettered free market. It was a pledge to make the US government an active meddler in the market, negotiating trade deals, bringing back jobs. His public bullying of big companies – pressing Ford or the air-conditioner manufacturer Carrier to keep their factories in the US – was precisely the kind of big government intrusion upon the natural rhythms of capitalism that appalled Rand.

So why does Trump claim to be inspired by her? The answer, surely, is that Rand lionises the alpha male capitalist entrepreneur, the man of action who towers over the little people and the pettifogging bureaucrats – and gets things done. As Jennifer Burns puts it: “For a long time, she has been beloved by disruptors, entrepreneurs, venture capitalists, people who see themselves as shaping the future, taking risky bets, moving out in front of everyone else, relying only on their own instincts, intuition and knowledge, and going against the grain.”

The acolytes: Republicans Rand Paul and Paul Ryan, and the late Steve Jobs of Apple. Composite: Getty Images

Which brings us to the new wave of Randians, outside both politics and conventional conservatism. They are the princes of Silicon Valley, the masters of the start-up, a cadre of young Roarks and Galts, driven by their own genius to remake the world and damn the consequences.

So it should be no surprise that when Vanity Fair surveyed these tycoons of the digital age, many of them pointed to a single guiding star. Rand, the magazine suggested, might just be “the most influential figure in the industry”. When the CEO of Uber, Travis Kalanick, had to choose an avatar for his Twitter account in 2015, he opted for the cover of The Fountainhead. Peter Thiel, Facebook’s first major investor and a rare example of a man who straddles both Silicon Valley and Trumpworld, is a Randian. Meanwhile, Steve Jobs is said by his Apple co-founder, Steve Wozniak, to have regarded Atlas Shrugged as one of his “guides in life”.

Among these new masters of the universe, the Rand influence is manifest less in party political libertarianism than in a single-minded determination to follow a personal vision, regardless of the impact. No wonder the tech companies don’t mind destroying, say, the taxi business or the traditional news media. Such concerns are beneath the young, powerful men at the top: even to listen to such concerns would be to betray the singularity of their own pure vision. It would be to break Rand’s golden rule, by which the visionary must never sacrifice himself to others.

So Rand, dead 35 years, lives again, her hand guiding the rulers of our age in both Washington and San Francisco. Hers is an ideology that denounces altruism, elevates individualism into a faith and gives a spurious moral licence to raw selfishness. That it is having a moment now is no shock. Such an ideology will find a ready audience for as long as there are human beings who feel the rush of greed and the lure of unchecked power, longing to succumb to both without guilt. Which is to say: for ever.