> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.co-din.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# How can I open the chatbox on click on a custom button?

Articles on: [Developers](/en/category/developers-12l9l8o/)

The Crisp chatbox can be opened and closed via your website JavaScript code. This allows you to create custom "Chat with us" buttons on your website, and trigger the Crisp chatbox to open when a visitor clicks on such buttons.  
  
You can use the following JavaScript code to open the Crisp chatbox:  
  

``` $crisp.push(['do', 'chat:open']);```

  
  
You can call it directly when an user clicks on a button:  
  

``` Click Me!```

  
  
Want to know more about the $crisp interface? Read: [How to use $crisp Javascript SDK?](https://docs.crisp.chat/guides/chatbox-sdks/web-sdk/dollar-crisp/)  
  
Don't forget to [subscribe to our Youtube Channel](https://www.youtube.com/channel/UCBgCqEfwt_454jVG7qpi_KQ?sub_confirmation=1) for tips and tricks about Crisp and customer service

Updated on: 13/03/2024