On any site where you can edit the HTML (a custom site, a site builder, a shop platform), the widget is one line of code. On WordPress, the plugin is easier. Install on WordPress
-
Copy the code
In your dashboard, open “Widget & calls”, choose “Other websites” in the “Install” card and click “Copy”. The code looks like this:<script src="https://zangzan.ir/assets/widget/widget.js" data-key="pk_…" defer></script> -
Paste it on every page
Paste it just before </body>, usually in your site's footer or theme template, so it loads on every page. Paste it once only. -
Add your site's domain
For your security, the widget only runs on the domains you add. In the same “Install” card, add your site's address without https://, for example shop.ir.
Which domains to add
- If visitors reach your site both with and without www, add both: shop.ir and www.shop.ir.
- To allow every subdomain (blog.shop.ir, www.shop.ir), add *.shop.ir.
- The address must match what's in the browser's address bar. Ports and paths aren't needed.
Show your team who the visitor is (optional)
If visitors sign in to your site, pass their details to the widget so your team sees their name before answering:
Zangoo.identify({name: "…", phone: "…", email: "…"})
These details show as unverified. To have them verified, your server signs them with the widget secret; the “Install” card has an example under “Show your team who the visitor is”.
Your own buttons (optional)
Any button or link with a data-zangoo-action attribute opens Zangoo when clicked, with no other code:
<button type="button" data-zangoo-action="chat">Chat with us</button>
The action can be call, chat, voice (a voice message), order, track (order tracking) or open (Zangoo's first screen).
Check that it works
Open your site: the Zangoo button is in the corner. Within a few minutes, the “Install” card shows where the widget was seen. Not there? Check the domain, clear your site's cache, and make sure the code is on the page only once.