It all depemds on what you’re trying to do. If it’s broadcast or short-wave reception, the higher the better, particularly if you’re in a fringe area. If you’re in a metropolitan area and all the transmitters are close, well, that’s when those old “rabbit ears” antennas worked satisfactory.
Lots of people these days have homeowners’ association rules that prohibit rooftop antennas, although they are being challenged. Check your CC&Rs if you have any, and if you do, indoor is pretty much your only choice. I’m fortunate to live in a fairly small city with all our broadcast antennas situated on the same mountain, and an attic antenna, mounted on a gable wall, works well.
If it’s just wi-fi or something like that, locate your hub as centrally as possible, avoidinng metallic furniture, ductwork and plumbing.