The Fountainhead is the story of Howard Roark, an architect who refuses to compromise his vision or his principles for anything. Roark is opposed by populist guru Ellsworth Toohey and newspaper magnate Gail Wynand, men who epitomize compromise and dishonesty in industry. He becomes romantically involved with Dominique Francon, later Wynand, a woman of mercurial temperaments. The novel deals with the philosophy of Objectivism, the lionization of Capitalism, and the importance of individual freedoms and vision.
In the spring of 1922, Howard Roark is expelled from architecture school for refusing to adhere to the school's conventionalism. He believes buildings should be sculpted to fit their location, material, and purpose, while his critics insist that adherence to historical convention is essential. He goes to New York City to work for Henry Cameron, a disgraced architect whom Roark admires. Peter Keating, a popular but vacuous fellow student who Roark sometimes helped with projects, has graduated with high honors. He also moves to New York to take a job at the prestigious architectural firm of Francon&Heyer, where he ingratiates himself with senior partner Guy Francon. Roark and Cameron create inspired work, but rarely receive recognition, whereas Keating's ability to flatter brings him quick success. Keating works to remove rivals within his firm, and eventually he is made a partner.
After Cameron retires, Keating hires Roark, who is soon fired for insubordination by Francon. Roark works briefly at another firm, then opens his own office. He has trouble finding clients and eventually closes it down. He takes a job at a granite quarry owned by Francon. There he meets Francon's daughter Dominique, a columnist for The New York Banner , while she is staying at her family's estate nearby. There is an immediate attraction between them, leading to a rough sexual encounter that Dominique later describes as a rape. Shortly after, Roark is notified that a client is ready to start a new building, and he returns to New York.
Ellsworth M. Toohey, author of a popular architecture column in the Banner , is an outspoken socialist who shapes public opinion through his column and his circle of influential associates. Toohey sets out to destroy Roark through a smear campaign. Toohey manipulates one of Roark's clients into suing Roark. At the trial, prominent architects (including Keating) testify that Roark's style is unorthodox and illegitimate. Dominique speaks in Roark's defense, but he loses the case. Dominique decides that since she cannot have the world she wants, in which men like Roark are recognized for their greatness, she will live completely and entirely in the world she has, which shuns Roark and praises Keating. She offers Keating her hand in marriage. Dominique turns her entire spirit over to Keating, doing and saying whatever he wants, including persuading potential clients to hire him instead of Roark.
To win Keating a prestigious commission offered by Gail Wynand, the owner and editor-in-chief of the Banner , Dominique agrees to sleep with Wynand. When they meet, Wynand is so strongly attracted to Dominique that he buys Keating's divorce from her, after which Wynand and Dominique are married. Wanting to build a home for himself and his new wife, Wynand discovers that every building he likes was designed by Roark, so he enlists Roark to build the new house. Roark and Wynand become close friends, although Wynand does not know about Roark's past relationship with Dominique.
Washed up and out of the public eye, Keating pleads with Toohey for his influence to get the commission for the much-sought-after Cortlandt housing project. Keating knows his most successful projects were aided by Roark, so he asks for Roark's help in designing Cortlandt. Roark agrees to design it in exchange for complete anonymity and Keating's promise that it will be built exactly as designed. When Roark returns from a long trip with Wynand, he finds that the Cortlandt design has been changed despite his agreement with Keating. Roark dynamites the building to prevent the subversion of his vision.
Roark is arrested and his action is widely condemned, but Wynand orders his newspapers to defend him. The Banner' s circulation drops and the workers go on strike. Faced with the choice of closing the paper or reversing his stance, Wynand gives in; the newspaper publishes a denunciation of Roark. At his trial for the dynamiting, Roark makes a speech about the value of ego and the need to remain true to oneself. The jury finds him not guilty. Roark also wins over Dominique, who leaves Wynand for Roark. Wynand, who has finally grasped the nature of the "power" he thought he held, shuts down the Banner and asks Roark to design one last building for him, a skyscraper that will testify to the supremacy of man. Eighteen months later, the Wynand Building is under construction and Dominique, now Roark's wife, enters the site to meet him atop its steel framework.