Does the family of 3 include a child? And is there any possibility the child is an infant under Airbnb’s definition? (Under 2 years old)
If so, Airbnb doesn’t count “infants” in their guest count. A guest can bring up to 5 infants on a reservation. If that’s the cause, you can’t cancel them. You can add something to your house rules that says “Due to local regulations, ALL people are counted toward maximum occupancy, even infants.” to avoid this situation in the future.
If it’s an older child or adult, then the rest of advice here is good…
I have a house rule that only registered guests are allowed on the property.
When they reserve, the guest has to confirm the count and give me first and last name for each guest.
The week of their stay I send a welcome message “We have you down for X guests. Please let me know if there are any changes to your guest count or list”
I have a Ring video doorbell, so I know pretty quickly if they’ve arrived with extras, and I can use pictures or video as evidence.
Like @georgiahost says, at that point you need to make a choice on how you want to handle things.
Since you’re trying to operate legally, I’d get in touch with the guest ASAP. “Hey, guest! I noticed you arrived with 3 people. The legal limit on our listing is 2. You can either reduce your numbers or I can ask Airbnb to cancel your stay.”