The House With a Clock In Its Walls by John Bellairs
Begins with the orphaned Lewis Barnavelt, aged 10, being sent to live with his crazy Uncle Jonathan, and his batty neighbor Mrs. Zimmerman. The Uncle and the neighbor both turn out to be magicians (of the benevolent sort), and the grand old house they inhabit is filled with magical artifacts and mysteries, including a strange ticking sound reputed to come from a hidden clock. Matters get serious after the insecure Lewis, in an attempt to impress a friend, ignores his uncle's warning that he should never attempt magic. Creepy, scary fun ensues.