- Hugo Riemann. Analysis of J. S. Bach's Wohltemperirtes Clavier (48-Preludes and Fugues) (Augener) - 2 volumes can be downloaded from archive.org
- Frederick Iliffe. The Forty-Eight Preludes and Fugues of John Sebastian Bach Analysed for the Use of Students (Novello) can be downloaded from archive.org
- Ebenezer Prout. Analysis of J. S. Bach's Forty-Eight Fugues (Das Wohltemperirte Clavier) (Edwin Ashdown, 1910) can be downloaded from archive.org
- Kerman, Joseph. The Art of Fugue. Bach Fugues for Keyboard, 1715 - 1750 (University of California, 2005)
- Williams, Peter. Bach. The Goldberg Variations (Cambridge, 2004)
For Beethoven you can look for classics by Barry Cooper, Donald Dovey, Edwin Fischer, etc.
I personally like the short structural analysis in Beethoven's 32 Piano Sonatas. A Handbook for Performers, by Stewart Gordon (Oxford, 2017)