> ## Documentation Index
> Fetch the complete documentation index at: https://feddy.app/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# WordPress

> Add the Feddy widget to a WordPress site from your theme or a small plugin.

By the end of this page your site will have a chat button that opens Feddy on every page, and a message sent from it will be sitting in your inbox. It takes about five minutes.

## Before you start

* A Feddy project and its project ID. You'll find the ID under **Settings → Install** in the dashboard. No project yet? [Create one](/docs/getting-started/create-a-project) first.
* Access to your theme's files, or the ability to add a plugin. Nothing to install from npm; the widget is one script loaded from Feddy's servers.

<Steps>
  <Step title="Add the script">
    Add this to your theme's `functions.php`. If you'd rather not touch the theme, the same lines work in a small plugin file:

    ```php functions.php theme={null}
    add_action('wp_enqueue_scripts', function () {
      wp_enqueue_script('feddy', 'https://core.feddy.app/sdk/feddy.js', [], null, true);
      wp_add_inline_script('feddy', "Feddy.init({ projectId: 'fd_XXXXXXXXXXXXXXXX' })");
    });
    ```

    Two details worth knowing: the final `true` places the script at the bottom of the page so it never slows down your content, and `null` as the version stops WordPress from adding its own cache-busting suffix, so browsers cache the file the way Feddy intends.

    <Note>
      **The project ID isn't a secret.** It's visible in your page source, so anyone can find it, and that's fine: it only tells Feddy which inbox a message belongs to. Commit it like any other setting. There's nothing to protect, so keep it out of your secrets file.
    </Note>
  </Step>

  <Step title="Choose how users open it">
    By default, a floating chat button appears in the bottom-right corner of every page. If you'd rather open Feddy from a menu item or button, pass `launcher: false` to `init` and add a click handler that calls `Feddy.open()`.
  </Step>

  <Step title="Send yourself a message">
    Open the site, click the button, and send a message. Then open your inbox at [dash.feddy.app](https://dash.feddy.app): it's there, with the page URL and browser alongside.

    Reply from the inbox. Back on the site, the reply appears in the panel.

    <Check>
      That's the whole loop: a visitor writes in, you answer, and the answer reaches them on your site.
    </Check>
  </Step>
</Steps>

## Next steps

<CardGroup cols={2}>
  <Card title="Identify users" href="/docs/guides/identify-users">
    Tell Feddy who's logged in, so you see their name in the inbox and replies can reach them by email.
  </Card>

  <Card title="Unread badge" href="/docs/guides/unread-badge">
    Show the count on your own element when you've turned the floating button off.
  </Card>

  <Card title="Conversations" href="/docs/concepts/conversations">
    What you're looking at in the inbox, and what happens on its own.
  </Card>

  <Card title="Web SDK reference" href="/docs/reference/web">
    Every option and call in the widget.
  </Card>
</CardGroup>
