Basically, one thing Fitzgerald does in the novel is bashing the American Dream. We get to know characters who are at the highpoint of their American Dream, but still are not happy: Tom Buchanan is rich and has a beautiful wife, but still, as that isn't enough for him, he embarks on an affair with Mytle.
Daisy lives in pure luxury and is married, but cannot enjoy it because on the one hand she knows her husband is unfaithful and on the other hand she's still in love with Gatsby.
Gatsby himself has managed to rise from a dirt-poor farmboy to a wealthy gentleman, owning a house on long island and being able to throw glamorous parties, And still, this all means nothing to him because what he wants is "possess" Daisy as his wife.
That makes Daisy herself an embodiment of the American Dream, and since she's in between Gatsby and Tom, who both want to possess her, we learn that living the American Dream is only possible by crushing another one's dream. (This also reflects in the various social topics throughout the novel)
The theme behind the Great Gatsby is, while there are a few, mainly materialism. Fitzgerald meant to say through the work that to focus on only the physical things in life is to be unhappy. You can marry well (as Daisy did) or become extremely rich (like Gatsby) and still not have the correct purpose to your life. Gatsby was so set on turning back time to when Daisy was in love with him that he completely missed the fact that she was a silly and superficial person.
When you look at Nicholas, you see that, though he had no money, he was generally happy. He didn't need all the money and glamor in the world to be content. He was the exact opposite of his cousins, and because of that, he was at peace with his lot. That's why Nicholas lives to see the end of the book and Gatsby dies, while Daisy continues her unhappy life with a cheating husband.
The Great Gatsby was basically written by Fitzgerald to warn against the downfalls of greed. It was, after all, written in a time when materialism was becoming more known to the world.
Content will be erased after question is completed.