First, you need to access the popup editor page and navigate under "Targeting" > Then click on Create New Custom targeting rule (not available on the free plan).
EXAMPLE: If you came on a target site/URL from another page https://neilpatel.com/blog/seo-companies/
The highlighted ones are the referrer and the referrer domain
Referrer in HB would be neilpatel.com/blog/seo-companies/
Referrer Domain would be neilpatel.com