A key element in whether a work deserves to be considered a classic is this:
Has it permitted, invited, and rewarded good reading, by readers of multiple generations?
For an extended, lively, and rewarding discussion of what "good reading" is, I refer you to a very fine short book, An Experiment in Criticism by C. S. Lewis.
But, very briefly: Good reading is attentive reading. The reader is attentive to the words, imagery, possible irony, etc. Bad reading might be marked by reader attention that turns from what the words say to self-pleasing daydreams for which the words are just nudges. In good reading, the reader gains pleasure and perhaps insight from what is there in the book, story, etc.
A classic elicits good reading from readers of multiple generations and varying social contexts. Shakespeare's famous plays are classics although (I believe) they are often subjected to bad reading. Readers who make the effort to understand the plays on their own terms will find their attention rewarded. (It appears to me that many modern productions of Shakespeare foist the obsessions of directors etc. on the plays, getting between the audience and the text, etc.)
Related to this "good reading" criterion is this: Classic works are indispensable. Each may give us something we can't get elsewhere. If you haven't read and digested Hamlet, you cannot get that flavor somewhere else, except perhaps incidentally or mixed with other flavors. If Blake's Songs of Innocence and of Experience disappeared, nothing else would make the loss bearable. The same, I suppose, would be true of other classic works. Conversely, I don't suppose that popular thrillers are indispensable. You can get pretty much the same thing from Book X as from Book Y.