Skip to content
AI Chatbots AI Integrations AI App Rescue Websites Pricing Case studies Guides Log in

How to add ChatGPT to your website (3 ways, explained simply)

"Can we put ChatGPT on our site?" is one of the questions we get asked most. Yes, you can. Here are the three ways to do it, and which one we'd pick in your shoes.

SHORT VERSION

You don't embed ChatGPT itself. You add a chatbot that uses OpenAI's models through their API and answers from your own content. You can do it with a plug-in, a monthly chatbot tool, or a custom build. Whichever you choose, never put your API key in the website's front-end code.

First, a quick clarification

ChatGPT is OpenAI's consumer app, the one you log into at chatgpt.com. When people say "add ChatGPT to my website", what they actually want is a chatbot powered by the same models, sitting on their site and answering questions about their business.

That's done through the OpenAI API: a separate, pay-as-you-go account on platform.openai.com. Your ChatGPT Plus subscription, if you have one, doesn't come into it.

The other thing to know early: on its own, the model knows nothing about your opening hours or your refund policy. Every good website chatbot works by looking up the relevant bits of your content and handing them to the model with the visitor's question. Developers call this retrieval. You just need to know it's what stops the bot making things up.

Way 1: a plug-in for your website builder

WordPress, Shopify, Wix and most other platforms have chatbot plug-ins that connect to your OpenAI key.

  1. Create an account at platform.openai.com, add billing, and set a monthly budget limit.
  2. Create an API key.
  3. Install the plug-in and paste the key into its settings (check it stores it on the server, not in the page).
  4. Point it at your pages or upload your FAQs, then test it with real customer questions.

Best for: simple sites and owners happy to tinker. Downside: quality varies a lot between plug-ins, and the setup and testing are all on you.

Way 2: a hosted chatbot tool

Hosted tools give you a dashboard: upload documents, customise the widget, paste one snippet into your site. Many include live-chat handover to your team.

Best for: teams that want analytics and inbox features without any development. Downside: a monthly subscription that usually grows with usage, and your conversations stored on someone else's platform. Check what happens to your data if you cancel.

Way 3: a custom build on the OpenAI API

A developer builds the chatbot for your site. Here's roughly what that involves, so you can judge any quote you get:

  • A small server-side piece that holds your API key and talks to OpenAI. The website talks to this, never to OpenAI directly.
  • Your content, prepared: pages, PDFs and FAQs cleaned up and split into chunks the bot can look up.
  • Instructions that set the tone, what it may and may not answer, and when to hand over to a human.
  • The chat widget, styled to match your site.
  • Guard rails: rate limits so nobody can spam it, and logging so you can see what people ask.

Best for: businesses with real question volume, specific rules, or a need to connect the bot to a CRM or booking system. Downside: a higher upfront cost than a plug-in. Ours is $999 one-time, running on your own OpenAI account so there's no monthly fee from us.

The one mistake to avoid

Never put your OpenAI API key in your website's HTML or JavaScript. Anyone can open their browser's developer tools and copy it, then run up charges on your account. We see this in AI-generated code all the time. If it's already happened to you, create a new key and delete the old one today.

Which one should you choose?

If you just want to answer a dozen common questions and you like DIY, start with a plug-in. If you want a dashboard and live chat without touching code, try a hosted tool for a month. If you get a steady stream of questions, have rules the bot must follow, or want to own the whole thing, a custom build pays for itself.

Either way, before you start, read our breakdown of what an AI chatbot really costs. It covers the running costs and the bits people forget to budget for.

Related

Quick answers

Can I just embed ChatGPT on my website?

Not the ChatGPT app itself. What you add is a chatbot that uses the same OpenAI models through their API, connected to your own content so it answers about your business rather than the whole internet.

Do I need a ChatGPT Plus subscription?

No. ChatGPT Plus is the consumer app. Website chatbots use the OpenAI API, which is a separate, pay-as-you-go account on the OpenAI platform.

Is it safe to put my OpenAI API key in my website code?

No. Anything in your front-end code can be read by visitors. The key must stay on a server, with the website talking to that server instead.

Will the chatbot know about my business?

Only if you give it your content. A properly built chatbot looks up the relevant parts of your website, docs or FAQs for each question and answers from those, instead of guessing.

Want it done for you?

We'll set up a chatbot trained on your content, test it properly and hand you the keys.

Client login

Enter the email you use with codingWWW.

Let’s talk.

Tell us a little about your project and we’ll get back to you within 1 business day.

No spam, no sales script — a real developer replies.