Boston Legal was billed as a follow-on to The Practice, like Archie Bunker’s Place to All in the Family or Frasier to Cheers, but the continuity drift between the two is much more radical - characters that appear to be the same are quite different.
First and most obviously, Denny is significantly more impaired in The Practice, seeming to genuinely be confused when Allan Shore calls him “Dad” - in Boston Legal, Denny seems slightly confused from time to time, but mostly uses his impairment to do whatever he likes.
Anthony Heald played Judge Cooper in “The Practice” - a California judge who over-enunciates the word “Massachusetts” to mock the lawyers from Boston; in “Boston Legal” he’s a Massachusetts judge of the same name, with the same quirk - for no apparent reason.
Catherine Piper (played by Betty White) was a neighbor of Allan Shore when he was a child - in “The Practice” they loathe each other, and she perjures herself to screw over Allan’s client out of spite - but in “Boston Legal” she gladly comes to Allan for help, and he gladly gives it, with no sign of past hatred.
In The Practice, Allan has a woman lawyer friend who is mentally ill but very competent. She’s played by Sharon Stone, and thinks that God talks directly to her. In Boston Legal, Allan also has a woman lawyer friend with mental problems - but she’s played by a different actress with different symptoms.
I suspect a slightly alternate universe (which is also why none of his lawyer acquaintances from The Practice ever show up on Boston Legal).