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

# Upgrade to Commentify Pro

> Move from the MIT Commentify package to Pro without changing your comments table or Livewire component.

Pro layers on the free package. Existing `Commentable` models, `<livewire:comments />` tags, likes, reports, and guest rows keep working. You add a Composer repo, run the installer, and optionally mount React/Vue against the same data.

## From Commentify 4.x (free only)

<Steps>
  <Step title="Confirm core is on 4.x">
    Pro requires `usamamuneerchaudhary/commentify:^4.0`. Core 4.0 made `user_id` nullable and added `guest_name`, `guest_email`, `ip`, `user_agent`, `import_source`, and `import_id`.

    ```bash theme={null}
    composer require usamamuneerchaudhary/commentify:^4.0
    php artisan migrate
    ```
  </Step>

  <Step title="Install Pro">
    Follow [Installation](/quickstart). The installer publishes `config/commentify-pro.php` and overlays `core` onto `config('commentify')` **unless** `config/commentify.php` is still on disk.
  </Step>

  <Step title="Merge and delete the old config">
    If you previously published `config/commentify.php`, copy those values under `commentify-pro.core` and delete the extra file. Until you do, the overlay is skipped and the installer will tell you so.
  </Step>

  <Step title="Register commentable aliases">
    Livewire never needed aliases. The API and SDKs do:

    ```php theme={null}
    'commentables' => [
        'articles' => \App\Models\Article::class,
    ],
    ```

    The installer fills this from models that already use `Commentable`.
  </Step>

  <Step title="Register Filament Pro (optional)">
    Keep the free plugin. Add Pro beside it:

    ```php theme={null}
    ->plugins([
        \Usamamuneerchaudhary\Commentify\Filament\CommentifyPlugin::make(),
        \Usamamuneerchaudhary\CommentifyPro\Filament\CommentifyProPlugin::make(),
    ])
    ```

    See [Filament](/filament).
  </Step>
</Steps>

## From Commentify 3.x or earlier

Upgrade core to 4.x first (nullable `user_id`, guest columns, Livewire 4, Laravel 12/13). Then install Pro.

If you published Blade views, republish them — 4.0 adds `partials/guest-fields.blade.php`. If you copied `CommentPolicy` into your app, keep `create(?Authenticatable $user = null)` so guests can post when `allow_guests` is on.

## After composer update

Refresh the published JS (the installer overwrites vendor copies on purpose):

```bash theme={null}
php artisan vendor:publish --tag=commentify-pro-js --force
npm install
```

Do **not** put `@commentify/*` in Vite `optimizeDeps.include`. Vite caches that pre-bundle on the lockfile, so the browser keeps running a stale SDK after every publish. If you already did, remove it and delete `node_modules/.vite`. See [JavaScript](/javascript).

## Config keys that moved

| Old (`config/commentify.php`) | New (`config/commentify-pro.php`)                                                                                       |
| ----------------------------- | ----------------------------------------------------------------------------------------------------------------------- |
| Top-level core keys           | `core.*`                                                                                                                |
| —                             | `commentables`, `api`, `spam`, `guests`, `notifications`, `media`, `realtime`, `webhooks`, `badges`, `toxicity`, `gdpr` |

Runtime still reads `config('commentify.*')` inside core. Pro copies `core` onto that bag at boot.
