@ayusopatricia, thank you for your reply!
I’ve already configured both domains.
When I check the History of the contact, I can see that pages visited on example.com are tracked correctly, while pages visited on anotherdomain.com aren’t.
Now I’m trying to configure Mautic to be used on both domains following this discussion: