I’ve built many a bookshelf over the years and have always been frustrated by free-standing bookends, which tend to slip or tip.
Advertisement
KeyholeBit

I've built many a bookshelf over the years and have always been frustrated by free-standing bookends, which tend to slip or tip. So, while crafting a bookshelf for my great-granddaughter recently, I hit upon the idea of fully adjustable built-in bookends.

In the top of the shelf, I used a keyhole bit in my plunge router to make a stopped slot, as shown in the drawing. I plunged the bit 12 " deep into the center of the shelf, and then routed to near each end. That created a keyhole slot with a single entry hole that will be hidden by books.

After making the bookends, I drove a #10 x 112 " flathead wood screw into the bottom of each, leaving the head about 14 " proud. To install the bookends, insert the head of the screw into one of the keyholes and slide it where you want it. The pressure from a book or two leaning against the bookends prevents them from sliding away.
—Gerald "Jum" Coorough, Prairie du Chien, Wis.