# Setting up Web Chat on wordpress

If you set up your website with wordpress, we suggest you to embed code before the enclosing \</head> with the following plugin.

{% hint style="info" %}
Before installing the plugin, to protect your website data, please create a backup to prevent plugin incompatibilities. The following configuration is the suggested handling, you may achieve the same with alternatives. If any technical issues occur derived from the plugin itself, we hold no responsibility.
{% endhint %}

<figure><img src="/files/1ThBPHB1cCaCaGWyirJ5" alt=""><figcaption></figcaption></figure>

Firstly, go to "Plugins" page and search "Header and Footer Scripts".

<figure><img src="/files/o5BiETNLHa77v7sVqcF7" alt=""><figcaption></figcaption></figure>

After installation, you can find the plugin in Settings > Header and Footer Scripts.

<figure><img src="/files/PVWp1G83pZeQ0KhZyFNk" alt=""><figcaption></figcaption></figure>

After pasting the code into the field, click Save Settings to apply.&#x20;

{% hint style="info" %}
When there are many plugins installed in your wordpress, there might be incompatibility that interferes with your inserted code. We hence suggest you to insert the code into footer and set the priority to 99 to prevent unexpected change of the inserted code.
{% endhint %}

If you use Elementor as page builder, the change applied to header or footer may not immediately be reflected across all your web pages. In this case, you can go to Elementor > Tools > Regenerate Files & Data.

<figure><img src="/files/CXxT6sdfG5GpUjvJKf9j" alt=""><figcaption></figcaption></figure>

Then you can view the web chat plugin shown on your website.

<figure><img src="/files/2HXhGBfeURKFBYWVJyyq" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.chatalog.ai/settings/web-chat/setting-up-web-chat-on-wordpress.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
