Framework · Developer setup

AI live chat for Vue 3 and Nuxt, in one component

Add <ReplyzeChat> once to App.vue or app.vue, or install it with app.use(Replyze, { token }). The AI answers from your knowledge base and hands over to your team, and the useReplyze() composable lets your own buttons open the chat.

Card required · Cancel before day 15 and pay nothing

Replyze/vue-live-chat on GitHub

Last reviewed 2026-11-13

Replyze on Vue and Nuxt

4 steps · Developer setup

  1. 1Copy your widget token (wgt_...) from Settings → Integrations → Install widget in your Replyze dashboard.
  2. 2Install the package from GitHub: npm install github:Replyze/vue-live-chat
  3. 3Add <ReplyzeChat token="wgt_YOUR_TOKEN" /> once, next to the rest of your root component: App.vue in Vue, app.vue in Nuxt (app/app.vue in Nuxt 4).
  4. 4Deploy and open your site. Once the page has loaded, the chat launcher appears in the bottom corner.
Install
npm install github:Replyze/vue-live-chat

Why Replyze for Vue and Nuxt

  • One component in App.vue or app.vue, or a plugin, app.use(Replyze, { token }), when the chat needs no state from your components.

  • Nuxt 3 and 4 without a module or <ClientOnly>: the component renders nothing on the server and loads the widget once it is mounted, so server-rendered pages hydrate without a mismatch.

  • useReplyze() gives your own buttons open(), close() and toggle(), with the unread count as a read-only ref. It needs no plugin or provider, and works in Pinia stores and router guards too.

  • The widget's events are typed Vue events, such as @unread and @message:received, typed for Volar and vue-tsc.

  • Identity verification with a server helper: createUserHash() from @replyze/vue/server signs a signed-in user, for example in a Nuxt server route.

Install

Add Replyze to Vue and Nuxt

Install the Replyze Vue package and add <ReplyzeChat> once to your root component, or use app.use(Replyze, { token }). For Vue 3.3+ and Nuxt 3 or 4.

  1. 1

    Copy your widget token (wgt_...) from Settings → Integrations → Install widget in your Replyze dashboard.

  2. 2

    Install the package from GitHub: npm install github:Replyze/vue-live-chat

  3. 3

    Add <ReplyzeChat token="wgt_YOUR_TOKEN" /> once, next to the rest of your root component: App.vue in Vue, app.vue in Nuxt (app/app.vue in Nuxt 4).

  4. 4

    Deploy and open your site. Once the page has loaded, the chat launcher appears in the bottom corner.

Install @replyze/vue

npm install github:Replyze/vue-live-chat

@replyze/vue isn't on the npm registry yet, so this installs it from GitHub. npm builds it while it installs, so you need git.

Add <ReplyzeChat> once: App.vue in Vue, app.vue in Nuxt

<script setup lang="ts">
import { ReplyzeChat } from '@replyze/vue';
</script>

<template>
  <!-- your app: <RouterView />, <NuxtPage />... -->
  <ReplyzeChat token="wgt_YOUR_TOKEN" />
</template>

Replace wgt_YOUR_TOKEN with your widget token from Settings → Integrations → Install widget in your Replyze dashboard.

Replyze/vue-live-chatThe full README: props, events, identity verification, examples

Vue 3 and Vite: the component or the plugin

Two ways to add the chat; use one. The component, in App.vue, takes its props from your app's state and takes the signed-in user. The plugin, in src/main.ts, suits a chat that needs no state from your components: it takes the same options as the component's props, except user, and reads them once.

App.vue
<script setup lang="ts">
import { ReplyzeChat } from '@replyze/vue';
</script>

<template>
  <RouterView />
  <ReplyzeChat :token="token" />
</template>
Or the plugin, in src/main.ts
import { createApp } from 'vue';
import { Replyze } from '@replyze/vue';
import App from './App.vue';

createApp(App)
  .use(Replyze, { token: import.meta.env.VITE_REPLYZE_TOKEN })
  .mount('#app');
.env.local
# .env.local
VITE_REPLYZE_TOKEN=wgt_YOUR_TOKEN

Nuxt 3 and 4

The component renders nothing on the server and loads the widget in the browser once it is mounted, so it goes straight into app.vue (app/app.vue in Nuxt 4) or a layout. No <ClientOnly> and no Nuxt module are needed. Keep the token in runtimeConfig.

nuxt.config.ts
export default defineNuxtConfig({
  runtimeConfig: {
    replyzeIdentitySecret: '', // server only, from NUXT_REPLYZE_IDENTITY_SECRET (optional, see Identity verification)
    public: {
      replyzeToken: '', // from NUXT_PUBLIC_REPLYZE_TOKEN
    },
  },
});
app.vue (app/app.vue in Nuxt 4)
<script setup lang="ts">
import { ReplyzeChat } from '@replyze/vue';

const config = useRuntimeConfig();
</script>

<template>
  <NuxtPage />
  <ReplyzeChat :token="config.public.replyzeToken" />
</template>
.env
# .env
NUXT_PUBLIC_REPLYZE_TOKEN=wgt_YOUR_TOKEN

Your own chat button

useReplyze() returns the chat's state as read-only refs (status, isOpen, unreadCount) and the widget's methods, so any button can open the chat and show the unread count.

useReplyze() needs no plugin or provider. Calls made before the widget has loaded wait and run as soon as it starts.

A "Help" button with the unread count
<script setup lang="ts">
import { useReplyze } from '@replyze/vue';

const { toggle, unreadCount } = useReplyze();
</script>

<template>
  <button type="button" @click="toggle">Help<template v-if="unreadCount > 0"> ({{ unreadCount }})</template></button>
</template>

Identity verification

Without verification, identify() only labels the visitor. With it, a signed-in user of your app is the same contact on every device and browser, with their past conversations, marked as verified in the inbox, and nobody can chat as someone else by calling identify() with their email. Turn it on in Settings → Chat Widget → Identity and keep the secret on your server: in Nuxt, in runtimeConfig outside public (NUXT_REPLYZE_IDENTITY_SECRET). A server route signs the user's id with createUserHash() from @replyze/vue/server (an HMAC-SHA256, with Web Crypto only), and app.vue passes the user to <ReplyzeChat :user="user" />. A user of null after a sign-out resets the chat, so the next person on a shared computer starts fresh.

In practice

How Replyze fits into Vue and Nuxt

@replyze/vue loads the same widget as the HTML snippet. The first <ReplyzeChat> (or the plugin) sets window.ReplyzeConfig and adds one async script for https://cdn.replyze.chat/widget.js to <head>. More instances, re-renders and remounts don't add another. The widget draws everything inside one shadow root, over the page.

Nothing touches window during setup or render, and nothing is kept between requests, so it is safe to render on the server. During hydration useReplyze() reads as it did on the server (idle, closed, 0) and switches to the widget's state once the component is mounted. By default widget.js is requested after the page's load event, when the browser is idle.

If widget.js is already on the page (the HTML snippet, or a tag manager), the package uses that widget instead of loading a second one. The widget token isn't a secret: it only lets the chat talk to your workspace. API keys (rpz_live_...) are secrets, and the package refuses to load with one.

@replyze/vue isn't on the npm registry yet. npm install github:Replyze/vue-live-chat installs it from GitHub, and npm builds it while it installs, so the install needs git. You still import it as @replyze/vue.

What visitors on Vue and Nuxt get

AI first, your team when it matters

  • Answers from your own help articles

    The AI replies in the visitor's language from the articles you publish and the answers your team teaches it. If the answer isn't there, it says so instead of guessing.

  • A person when it matters

    Visitors can ask for a person at any time, and topics your industry setup marks for the team, such as refunds and complaints, are handed over too. The teammate replies in the same chat, with the whole conversation in front of them.

  • Chat, email and messaging in one inbox

    Web chat on every plan. Email, WhatsApp and Telegram on Pro and Business, with Messenger and Instagram in beta, all in one shared inbox.

See every feature

FAQ

Vue and Nuxt + Replyze, answered

Not yet. Install it from GitHub with npm install github:Replyze/vue-live-chat. You import it as @replyze/vue. npm builds the package while it installs, so the install needs git.

Not needed. The component works in app.vue with server rendering, and a client plugin (plugins/replyze.client.ts) covers the rest.

In the Replyze dashboard: Settings → Chat Widget → Launcher, "Pages the widget shows on". Or from code, with hide() and show(), for example in a router guard. After show(), the widget shows everywhere regardless of the page rules, so use one or the other.

Check status from useReplyze() and the browser console. "error" with "Could not load https://cdn.replyze.chat/widget.js" is a network error, an ad blocker or your Content-Security-Policy. "Widget blocked: this domain ... is not in the widget's allowed-domains list" means the domain (or localhost while you develop) has to be added in Settings → Chat Widget. "idle" means no <ReplyzeChat> with a token was mounted; in Nuxt, check that NUXT_PUBLIC_REPLYZE_TOKEN is set where the app runs.

Yes. Import Replyze and call its methods (Replyze.open()), or call useReplyze() in setup(). <ReplyzeChat> works in any template.

Yes. react-live-chat (see the React and Next.js guide), react-native-live-chat and flutter-live-chat, all on GitHub under github.com/Replyze.

Get your Vue and Nuxt chat ready for customers

Once the widget is installed, give it useful answers and connect it to the people who will reply. These examples cover what to publish, where to test the chat and how to handle the first enquiries from your Vue and Nuxt site.

Read more: Get your Vue and Nuxt chat ready for customers

What will visitors ask on your Vue and Nuxt site?

“Can I export my data?” is one question to try. It is the kind of detail a visitor may want while reading a page, before sending a message or making a purchase. Start with the questions your team hears most often about account settings, data exports and billing contacts. Write the answer in a Replyze help article, using the same terms and conditions customers see on the website. Include the next step and a useful link when the customer needs another page.

Open the page where that question is likely to come up and ask it in your own words. Then ask a follow-up: “What if my situation is different?” Read both replies and request a person. This gives you a first check of the answer and the connection to your team before you invite customers to use chat.

A visitor on Vue and Nuxt can ask a question while reading the page and continue with your team.
A visitor on Vue and Nuxt can ask a question while reading the page and continue with your team.

Before and after adding chat to Vue and Nuxt

Before: someone looking for account settings, data exports and billing contacts may search the navigation, open a contact form and wait for an email. A clear website already answers many of these questions, so look for the points where people still get stuck. Your last few customer messages can show which explanation is missing or hard to find.

After: the visitor asks in the widget and receives an answer from the articles you have published. If the question concerns their own order, appointment or account, the team can continue in the same conversation. For example, a general policy question can lead into “Can you check my request?” The first answer stays visible when a colleague takes over, along with the details the customer has already shared.

Example contact journey: a Vue and Nuxt visitor asks on the page and the team can continue the same chat.
Example contact journey: a Vue and Nuxt visitor asks on the page and the team can continue the same chat.

Which help articles should you prepare first?

Create a short article for each of your main topics: account settings, data exports and billing contacts. Explain the usual answer, the conditions that change it and the contact route for an individual request. Use your current website information as the starting point. The widget connects your site to Replyze; add the information you want the assistant to use in the knowledge base as a separate setup step.

If those answers already live in a document, Write with AI can prepare draft articles for you to check. Read the dates, amounts and exceptions carefully before publishing. Remove old versions that disagree with the new answer. When you change a policy on your Vue and Nuxt site, update the corresponding article too so customers get the same explanation in both places.

Prepare help articles about account settings, data exports and billing contacts before opening the chat to customers.
Prepare help articles about account settings, data exports and billing contacts before opening the chat to customers.

Where should the Vue and Nuxt component go?

Add the component once to App.vue or app.vue, then check a direct page load as well as navigation between routes. Start with the first installation step above: Copy your widget token (wgt_...) from Settings → Integrations → Install widget in your Replyze dashboard. Use the widget token from the Replyze workspace that belongs to this website and follow the remaining platform steps. The workspace setting determines where the messages arrive, so check it before publishing, especially if you manage several brands or client sites.

Render the component once, near the root of the app. If another person previously added chat through a theme, a custom-code setting or a tag manager, locate that copy before adding a new one. Two installations can make troubleshooting confusing. Tell the person maintaining the site where you placed it, so the next theme update or redesign includes the same check.

Use the Vue and Nuxt installation steps and the widget token for this website’s Replyze workspace.
Use the Vue and Nuxt installation steps and the widget token for this website’s Replyze workspace.

What happens when a visitor needs a person?

Try a follow-up that needs somebody to check an individual request: “Can you change this for me?” The chat should explain how to reach the team and keep the conversation available for the person who responds. The website installation provides chat; account changes, order checks and booking confirmations still use the business systems and people responsible for them.

Ask directly for a teammate as well. Open the shared inbox and read the conversation from the receiving person’s side. Can they see what the customer wants and what has already been answered? Set the opening hours and contact instructions your team can actually support. When nobody is available, the customer needs a way to leave a contact detail and a clear expectation for the reply.

A teammate can continue the Vue and Nuxt conversation with the earlier messages available.
A teammate can continue the Vue and Nuxt conversation with the earlier messages available.

Should chat replace your contact form?

Keep a contact form when it helps customers send a detailed enquiry in one go. A project brief, a request involving several products or a message sent outside office hours may suit that format. Chat is useful when somebody has a short question and wants to ask a follow-up while looking at the page. The two contact options can serve the same website.

Try both routes with the question “Can I export my data?”. Check which one helps the visitor reach an answer comfortably. On a phone, open the chat alongside any cookie notice and the page’s main button. Make sure customers can still continue browsing, submit the form or complete their purchase. Adjust the widget placement through its available settings if it covers an important control.

Keep useful contact options available and check the widget beside your Vue and Nuxt page controls.
Keep useful contact options available and check the widget beside your Vue and Nuxt page controls.

Which Vue and Nuxt pages should you check?

Start with the first page load and two route changes in the router. These checks catch differences between templates and publishing settings that a homepage-only test can miss. Visit each page directly, then navigate between them as a customer would. Confirm that the chat opens and that a message reaches the same intended workspace from each location.

Some parts of a platform have their own code restrictions or access settings. Use the platform instructions above when checking a checkout, customer account or other restricted area. Keep your existing support link available wherever the widget is not installed. A simple list of the pages you have checked helps the website maintainer repeat the right tests after a redesign.

Check the first page load and two route changes in the router after publishing the Vue and Nuxt installation.
Check the first page load and two route changes in the router after publishing the Vue and Nuxt installation.

How can you tell that messages reach the right team?

Send a message labelled “Website chat test” from the published Vue and Nuxt site and find it in Replyze. Reply as a teammate and check that the answer appears in the visitor’s chat. Request a human handover and verify the notification route the team uses. This confirms the path in both directions.

For an agency or a business with several websites, repeat the test for each workspace. Check that the help articles and team access belong to the same business as the site. Ask the colleague who will answer real enquiries to try a reply. They should know where the conversation appears and which contact instructions customers see outside opening hours.

Follow a test message from your Vue and Nuxt website into the team inbox and back to the visitor.
Follow a test message from your Vue and Nuxt website into the team inbox and back to the visitor.

What if the widget is missing on Vue and Nuxt?

First check the published site in a fresh browser window. Confirm that the installation change was saved and published, and follow any cache instructions in the guide above. Add the component once to App.vue or app.vue, then check a direct page load as well as navigation between routes. Check where the component renders and the token it receives before changing anything else. A missing publish step or a different active template can explain why a change appears in an editor but not on the public website.

Once the widget appears, test typing, opening and closing it on a phone. Navigate to another page and try again. Keep the previous website configuration in your normal version history so the site maintainer can undo a mistaken placement. Removing the component from the website is a separate task from managing the Replyze workspace and its conversations.

If Vue and Nuxt chat is missing, check publication and placement before adding a second component.
If Vue and Nuxt chat is missing, check publication and placement before adding a second component.

What should you update after launch?

Read the first enquiries about account settings, data exports and billing contacts. If several people ask the same question, improve the relevant help article and the page that prompted it. When a reply needs a teammate, check whether that person had enough information to continue. A useful first week often reveals a missing policy detail or a confusing link that is easy to fix.

Repeat the installation check after a theme change, a new template or a platform migration. Repeat the answer check when your services or policies change. Give the website maintainer the page list and give the support team the sample questions. That keeps both parts of your Vue and Nuxt chat working as the site grows.

Keep the Vue and Nuxt installation and the answers about account settings, data exports and billing contacts up to date.
Keep the Vue and Nuxt installation and the answers about account settings, data exports and billing contacts up to date.

Let AI answer the questions you get every day

Teach it your answers, pick your colours and add it to your site. When a customer needs a person, your team takes over.

Card required · Cancel before day 15 and pay nothing. No card? Start on the Free plan, with 50 AI replies once for a new account's first month.