There are HUGE variables that are relevant in every family so how we do it might not be relevant to how you do it. Here are just a few I can think of:
1 Size of your house/space to have guests
2 Financial resources. Yours and your visiting family's
3 Distance family are travelling from
4 Relationship with family, including with in laws etc
5 Lifestyle and needs within your home eg specific chidlcare issues, logistics etc
So, we cannot fit family into our house. So when they come, they stay with other family or they have to book into an Airbnb. If they're not staying with us, they are, of course, welcome to stay as long as they like but, I'd rearrange a lot to see family from far away for 2 days, but I'm not rearranging my life if MIL turns up for 6 weeks (we did have to make this point on one occasion, yes). If they are staying elsewhere but mostly here to see us, we do our best to facilitate contact and visits - meals at ours, invite them to attend activities or events with us, possibly plan specific activities especially. Money is tight at the moment so that would impact decision making too.
If we had a bigger house, I'd let them stay, but I'd need a time limit, varying according to who the family visiting are and why they're in town. My brother and his family have tended to overstay their welcome at various other family member's houses without careful boundaries being put in place up front.