A website widget is a small, self-contained tool that sits on a web page and does one job, such as a chat button, a booking form or a row of customer reviews. The site owner adds it with a short piece of code, a plugin or an app. It usually runs from the provider's servers.
So a widget on a website is a feature you add to a page without building it yourself. This guide lists the common types, shows how one gets on a page, and explains what to check before you add one.
Open the website of a local dentist. The opening hours, the photos and the text were written for that practice. The map came from a map service. The "Book now" calendar came from a booking provider. The small round button in the corner came from a chat provider. Those last three are widgets. To the patient they look like one page, but each one is supplied by a different company.
The word comes up in other places too. Phones and desktops have widgets for weather and calendars, and those are a separate thing. This article is about widgets for websites.
Common types of website widgets
| Type | What the visitor sees | Why the owner adds it |
|---|---|---|
| Chat | A button in the corner that opens a conversation | To answer questions on the page |
| Cookie consent | A banner with accept and decline choices | To record what the visitor agrees to |
| Reviews | Star ratings and customer comments | To show what buyers said |
| Booking | A calendar with free times | To take appointments without phone calls |
| Sign-up form | A field for an email address | To build a mailing list |
| Map | An interactive map with a pin | To show the location and directions |
| Social feed | Recent posts from a social account | To keep the page current |
| Video player | A video that plays on the page | To show a video stored elsewhere |
| Search | A search field with results | To help visitors find pages and products |
| Language switcher | A menu of languages | To serve visitors from other countries |
What they share is more useful than how they differ. Each one has a small visible part on your page and a larger part that lives with the provider, such as the reviews database or the booking calendar. The provider can update that larger part without any change to your site.
Widget, plugin, app or embed?
People use these words loosely, and a provider may use all four on one page. These are the usual meanings.
The feature the visitor sees on the page. This word describes the result, however it was installed.
An add-on installed into your website software, such as WordPress. A plugin can put a widget on your pages, and it can also do jobs visitors never see, such as backups.
The same idea on a hosted platform. Shopify and Wix both call their add-ons apps.
The act of placing outside content in your page with a piece of code. The code you paste is often called an embed code.
WordPress adds one more meaning. Its own "widgets" are blocks of content for areas such as the sidebar and footer, for example a list of recent posts. Those are part of WordPress and do not need an outside provider.
How a widget gets on a page
Paste a code snippet
The provider gives you a line or two of code. You add it to your page template, usually just before the closing body tag, so it appears on every page.
Use your builder's code area
Site builders have a place for this. Squarespace calls it Code Injection, and Wix calls it Custom Code. You paste the same snippet there.
Install a plugin or app
On WordPress you install a plugin. On Shopify you install an app and switch on its app embed in the theme settings. You then connect it to your account.
Add it with a tag manager
If your site uses a tag manager, a marketer can add the snippet there without a change to the site's code. Note where it is, so you can find it later.
A typical snippet looks like the line below. The address is an example.
<script src="https://widgets.example.com/loader.js" async></script>
This line tells the browser to fetch a small program from the provider. The word async matters: the browser keeps building your page while that file downloads. A script without async or defer makes the browser stop and wait for it, so a slow provider can hold up your page.
Once the program runs, it adds the visible parts to the page. It may also fetch further files, such as styles, settings and images. That is why one line of code can lead to many network requests, and some of them may go to other companies' servers.
Some loaders go a step further and wait for the page to finish loading before they fetch anything. Asyntai's chat snippet works that way. It waits for the browser's load event, then adds its script with async.
What to check before you add a widget
- Does it solve a real problem? Write down the job in one sentence, such as "stop phone calls about opening hours". If you cannot, leave it off the page. Every widget is one more thing to load and to look after.
- How is it loaded? Read the snippet. Look for
asyncordefer, or a loader that waits for the page. - What does it do to your page speed? Measure this on your own site with the steps in the next section. A provider's general claim tells you less than a test on your own pages.
- How does it look on a phone? Open the page on a real phone. Check that the widget does not cover the buy button, the menu or the cookie banner.
- Does it work with your cookie banner? Some consent tools hold back outside scripts until the visitor makes a choice, so the widget may not appear at first. Ask your adviser what your site must do, and test it in a private window.
- What data does it collect? Read the provider's privacy terms and note where the data goes. Your own privacy policy may need to mention it. Check this point with your adviser.
- Can people use it without a mouse? Press the Tab key until you reach the widget, and try to open and close it. Contrast and label text matter as well.
- Can you restyle it? Check that you can set the colours, the position and the language to suit your site.
- What happens if the provider goes down? Your page should still work. Ask whether anyone would notice if the booking form stopped loading on a Sunday.
- How do you remove it? Old widgets are easy to forget. Record where each snippet lives. When you stop paying for a tool, remove its code from the theme, custom code areas and the tag manager.
How to see what a widget does to your page
You can test this with free tools in the Chrome browser, and you need no help from the provider. The numbers on your own site are the ones that count, because they depend on your pages and your visitors' devices.
Open DevTools, choose the Network tab and reload. Sort by domain. Rows that are not your own domain come from outside providers. Note how many there are and their total size.
In DevTools, run Lighthouse on the Mobile setting, with and without the widget. Compare the page speed results. The report also lists third-party code and its effect.
Enter your address at PageSpeed Insights. If your site has enough traffic, it also shows data from real visits, including Largest Contentful Paint and Interaction to Next Paint.
Run each test more than once, because results vary between runs. Change one thing at a time, so you know what caused any difference.
A chat widget as a worked example
A chat widget shows why the small visible part can hide a lot. Asyntai is the example we know best, because we make it. Your visitor sees a button. Behind it, an AI reads your website and the files you give it, then answers from them.
A visitor on a furniture site might ask, "Do you deliver to the islands?" or "Can I return a sofa after two weeks?" Your visitor gets an answer on the same page, and you can read the conversation later in your chat logs. You can choose the colours and hide the widget on the pages where you do not want it. The position setting starts at the Starter plan, and the other button designs are on Pro.
Adding it follows the methods above. There is a code snippet for any website, a WordPress plugin and a Shopify app. Other platforms are in the installation guide. The Free plan includes 50 messages a month, and one message is one AI reply. To go deeper on this type, read our guide to live chat widgets.
Frequently asked questions
What is a widget on a website, in simple terms?
It is a small tool from an outside provider that appears as part of your page, such as a chat button, a map or a booking calendar.
What is an example of a website widget?
A cookie banner, a star rating from a review service, an embedded video and a chat button are all common examples.
Do I need to know how to code to add a widget?
Usually not. You copy a snippet into a settings field in your site builder, or you install a plugin or an app. On a custom-built site, your developer can add the snippet to the page template.
Do widgets slow down a website?
They can, because each one adds files for the browser to fetch and run. The effect depends on the widget and on how it loads, so test your own pages with and without it.