What is a WhatsApp chat button?
A chat button is the small round icon fixed in the corner of a website that opens a WhatsApp conversation with the business when clicked. It is one of the simplest ways to turn visitors into leads: customers can ask a question at the exact moment they hesitate, using the app they already have open all day.
Many plugins add such a button, but they often load heavy scripts, track visitors or require a paid plan. This generator produces a tiny, self-contained snippet of HTML, CSS and a few lines of JavaScript, with no external requests. You choose the color, the corner, the distance from the bottom, the label and whether a friendly greeting popup appears before the chat opens.
The code works on any site where you can add HTML: WordPress, Shopify, Wix (custom code), Webflow, Squarespace, Joomla, a PHP site or a static HTML page. The preview on the right shows exactly what your visitors will see.
How to add a WhatsApp button to your website
Enter your WhatsApp number
Select the country code and type the number that should receive the chats. Add a pre-filled message so you know the request came from the website.
Style the button
Choose a label (or leave it empty for an icon-only button), the button color, the left or right corner and the distance from the bottom.
Configure the greeting popup
Keep the popup enabled to show a title, a welcome message and a “Start chat” button, or disable it for a direct link.
Copy the code
Click “Copy code”. You can also download the snippet as an .html file to keep a copy.
Paste it into your site
Paste the code just before the closing
</body>tag, or in your platform’s footer/custom code area, then save and test on mobile.
Installing the button on popular platforms
WordPress
Use a header/footer code plugin (for example “WPCode”) and paste the snippet in the footer section, or add a Custom HTML block in your theme’s footer widget area. Full steps are in our website button guide.
Shopify
Go to Online Store › Themes › Edit code, open theme.liquid and paste the snippet just above </body>.
Wix, Squarespace and Webflow
Use the “Custom code” or “Code injection” setting and add the snippet to the footer of all pages.
HTML and PHP sites
Paste the snippet into your shared footer template so it appears on every page.
Tips for a button that gets clicks
- Use a pre-filled message such as “Hi, I have a question about…” so visitors do not have to think about what to write.
- Show your reply hours in the greeting message to set expectations.
- Check that the button does not hide a cookie banner, a cart button or a back-to-top arrow on mobile; adjust the bottom distance if needed.
- Keep high contrast between the button color and your page background.
- For a “share this page” button rather than a contact button, use the share link generator.