The earliest novel-length published work with Elves in a recognizable "modern fantasy mode" is most likely Le Morte d'Arthur , by Sir Thomas Mallory, finished around 1470, and first published in 1485.
While Le Morte is literally nothing new, even when written, it's one of the earliest written works with recognizable, embodied fae in human shape, and armed and armored as men.
Note that Le Morte draws heavily on many tales and stories later recorded elsewhere
; it comes together, however, as the definitive Arthurian tale, and the Fair Folk within are credited as inspiration for many later versions of Aelfdom...
scifi.stackexchange.com/users/1367/aramis
The name elf has been borrowed from mythology, so the term itself has been used for perhaps several thousand years.
However the term refers to different kind of beings depending on time and place.
The wiki page on elves gives an introduction to the concept of elves in different mythologies.
In mythologies they are either treated as Semi-divine and powerful magical beings; or Small, mischievous beings (i.e. a subset of fairies) Note that in the first case, they are either divided into light and dark elves, or represent light with dwarves representing the dark.
In fantasy, they have been popularised by Tolein into a very standard image, but people still use some alternate representations for them.
This is discussed in detail at this wiki page - Elves in fantasy fiction and games .
A summary of the article states that The fantasy genre in the 20th century grows out of 19th century Romanticism.
19th century scholars such as Andrew Lang and the Grimm brothers collected "fairy-stories" from popular folklore and in some cases retold them freely.
A pioneering work of the genre that would come to be known as "fantasy" was The King of Elfland's Daughter, a 1924 novel by Lord Dunsany.
The Hobbit by J. R. R. Tolkien (1937) is seminal, predating the lecture On Fairy-Stories by the same author by a few years.
In the 1939 lecture, Tolkien introduced the term "Fantasy" in a sense of "higher form of Art, indeed the most nearly pure form, and so (when achieved) the most potent".
Elves played a central role in Tolkien's legendarium, notably The Silmarillion.
Tolkien's writing has such popularity that in the 1960s and afterwards, Elves speaking an Elvish language similar to those in Tolkien's novels (like Quenya, and Sindarin) became staple non-human characters in high fantasy works and in fantasy role-playing games.
Post-Tolkien fantasy elves (popularized by the Dungeons & Dragons role-playing game) tend to be more beautiful and wiser than humans, with sharper senses and perceptions.
They are said to be gifted in magic and mentally sharp and are characterized as lovers of nature, art, and song.
A hallmark of fantasy elves is their long and pointed ears (a convention begun with a note of Tolkien's that the ears of elves were "leaf-shaped").[22] Also note that in popular culture, Christmas elves are very different from Tolkienian elves, and are closer to fairies.
scifi.stackexchange.com/users/947/apoorv020
I don't think there's going to be a definitive answer to this...
Elves have been a part of folklore since long before any 'modern' books, and quite possibly before books even existed.
scifi.stackexchange.com/users/1624/Asmor
Brewer (17th Ed): Elf [...] Originally a dwarfish being of Germanic mythology, possessed of magical powers which it used for the good or ill of mankind.
And then goes on to quote Shakespeare.
So in answer to: what's the earliest book that featured Elves?
A Midsummer Night's Dream is 1595 (strictly not a book on that date) so likely earlier.
scifi.stackexchange.com/users/204/Richard
I think faeries and elves came out of Irish mythology.
The Tuatha De Danann who are their gods were powerful beings skilled in magic.
Then the Christians (there's never any peace with them around) converted the Irish.
But the people still believed in the gods, only as faeries.
scifi.stackexchange.com/users/1951/Hank
The idea of Elves may be very, very old.
Hesiod (a contemporary of Homer) mentions the waves of the Golden race, Silver race, Bronze race.
Tolkien's chronology associates elves with the Silver race (as does the linguistic similarity: silver--silvan).
But the idea my also be autochthonous.
There's an Inuit legend about a village of petite people who had the power of making their bodies lighter or heavier at will.
scifi.stackexchange.com/users/3007/luser droog
Elves are a common appearance in many worlds in Fantasy. From Tokien, to Harry Potter, to Dungeons and Dragons, and Eragon. Many works feature Elves in some way, all with many common characteristics. But, I'm kind of curious, what's the earliest book that featured Elves?
What is the first appearance of Elves in fantasy?
scifi.stackexchange.com
<trope><elves>
scifi.stackexchange.com/questions/3159
scifi.stackexchange.com/users/98/PearsonArtPhoto
Faeries and elves are said to come from Irish mythology, so the idea of elves is very old. Elves have been a part of folklore since long before any 'modern' books, and quite possibly before books even existed.  However, the earliest novel-length published work with Elves is most likely  Le Morte d'Arthur , by Sir Thomas Mallory, finished around 1470, and first published in 1485.   A Midsummer Night's Dream  is 1595 and Hesiod (a contemporary of Homer) mentions the waves of the Golden race, Silver race, and Bronze race. Elves have been part of folklore, mythology and legend for an extremely long time, long before books were invented. Earliest publish works referring to Elves include Shakespeare's A Midsummer Night's Dream, 1595 and Le Morte d'Arthur, published in 1485.
A number of old books mention Elves, including A Midsummer Night's Dream, datingfrom 1595. A contemporary of Homer also mentioned the Golden race. The idea of Elves may be much older than books. They may stem from ancient mythology, folklore and legends.