While you could rely on a Realtor to make the determination, that is a risky proposition for both of you. And while the answer is essentially able to be found in the planning departments zoning regulations, and will very likely involve the a combination of the following factors
- Overall lot size
- % of lot which is back yard (remains beyond the primary residence's foot print)
- % of the remaining lot which is already covered by structure, garage, shed, pool, etc...
- set backs possible
So in a sense, with a big enough lot it can be a fairly quick & simple answer, but with smaller lots the many variables can make for a complex decision. So as a Realtor, it's not a wise idea to give financial or tax advise, anymore than I would want to give someone medical advice.
If I were buying a home or had a client that was, wanting the clear understanding it could have a Granny Unit added, I would want to talk with and expert. By the way these experts (architects typically) are typically knowledgeable about not only the applicable zoning codes, but more importantly having a track record the people in the town or county planning dept that handle such determinations.
So the real key is finding the right architect who know lots of the key players in the town or county department, hopefully from a judge. I'd be happy to provide the name of the architecture I prefer to use.