Middle English bok, from Old English boc "book, writing, written document," generally referred (despite phonetic difficulties) to Proto-Germanic *bōk(ō)-, from *bokiz "beech" (source also of German Buch "book" Buche "beech;" see beech), the notion being of beechwood tablets on which runes were inscribed; but it may be from the tree itself (people still carve initials in them).
Latin and Sanskrit also have words for "writing" that are based on tree names ("birch" and "ash," respectively). And compare French livre "book," from Latin librum, originally "the inner bark of trees" (see library).
The sense gradually narrowed by early Middle English to "a written work covering many pages fastened together and bound," also "a literary composition" in any form, of however many volumes. Later also "bound pages," whether written on or not. In 19c. it also could mean "a magazine;" in 20c., a telephone directory.
The use of books or written charters was introduced in Anglo-Saxon times by the ecclesiastics, as affording more permanent and satisfactory evidence of a grant or conveyance of land than the symbolical or actual delivery of possession before witnesses, which was the method then in vogue. [Century Dictionary]
From c. 1200 as "a main subdivision of a larger work." The meaning "libretto of an opera" is from 1768. A betting book "record of bets made" is from 1812. The meaning "sum of criminal charges" is from 1926, hence slang phrase throw the book at (1932). Book of Life "the roll of those chosen for eternal life" is from mid-14c. Book of the month is from 1926. To do something by the book "according to the rules" is from 1590s.
Middle English boken, from Old English bocian "to grant or assign by charter," from book (n.). The meaning "write down, record, enter into a book" is from c. 1200. The Old English sense is because the first books in English were records of grants or conveyances of land.
The meaning "to register a name for a seat or place; issue (railway) tickets" is from 1841; that of "to engage a performer as a guest" is from 1872. U.S. student slang meaning "to depart hastily, go fast" is by 1977, of uncertain signification. Related: Booked; booking.