Click to Chat : How to open WhatsApp chat from website button

If you want to have a “chat” button on your website which on Android mobile will directly start the Whatsapp application and send a predefined message to predefined contact number, just copy paste the below lines where ever you need.

<a href="" class="applyinfo-btn">start chat </a>

In above the message we are trying to send is “Hi we need help regarding something”, which when used in html we need to add “%20” for space hence it became as “Hi%20we%20need%20help%20regarding%20something”

For India, it will be 91 as country code in “phone=”, you can check your country code from

Subscribe with Valid Email Id to receive updates in Inbox. ( Secured by Google FeedBurner )


Refer page, If you want to add Android Share dialog to website using Web Share API

Refer more at


5 thoughts on “Click to Chat : How to open WhatsApp chat from website button”

    • It would have been better if you could add a credit backlink pointing to this webpage as you have copied some contents from this page. Thanks.


Leave a Comment

Android Android Build system Android Commands Android Java Applications Application Libraries Application Stack / User Interface Bash / Shell Scripts Bluetooth driver Cloud Technologies Commands and Packages Compilation Content Management System Core Kernel C Programs Development & Build Development, Debugging and Performance Tools Development Environment Setup Django & REST Api Errors & Failures Git Hardware Platforms HTML JAVA Programs Linux, OS Concepts and Networking Linux Device Drivers Linux Host, Ubuntu, SysAdmin Linux Kernel Linux Networking Middleware Libraries, HAL Multimedia Audio, Video, Images NDK / Middleware / HAL OS Concepts PHP Programming Languages Scripting and Automation Search Engine Optimisation ( SEO ) Social Media Source Code Management ( SCM ) System Administration, Security Testing and Debugging Uncategorized Web design and development Website Hosting Wordpress Yocto / Bitbake / Openembedded