> For the complete documentation index, see [llms.txt](https://docs.meganova.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.meganova.ai/character-studio/embed-widgets/creating-embeds.md).

# Creating Embeds

> **Note:** Learn how to create and deploy embed widgets for your characters. Set up chatbots on external websites with step-by-step instructions.

## Overview

Creating an embed involves:

1. Accessing embed configuration
2. Setting up appearance and behavior
3. Generating integration code
4. Deploying to your website

## Step 1: Access Embed Configuration

### From Character Studio

1. Open character in editor
2. Navigate to **Embed** tab (or section)
3. Click **Create Embed** or **Manage Embed**

### Embed Dashboard

Shows:

* Existing embeds
* Configuration options
* Integration codes
* Analytics

## Step 2: Basic Configuration

### Widget Name

Give your embed a name:

* For your reference
* Helps identify in analytics
* Example: "Homepage Chatbot"

### Character Selection

Choose which character:

* Default: Current character
* Can change later

## Step 3: Display Settings

### Theme

| Option    | Description             |
| --------- | ----------------------- |
| **Light** | Light background        |
| **Dark**  | Dark background         |
| **Auto**  | Match system preference |

### Dimensions

| Setting    | Recommendation    |
| ---------- | ----------------- |
| Width      | 350-450px         |
| Height     | 500-700px         |
| Responsive | Enable for mobile |

### Avatar

| Option     | Description              |
| ---------- | ------------------------ |
| **Show**   | Display character avatar |
| **Hide**   | No avatar                |
| **Custom** | Use different image      |

### Border

| Setting | Options         |
| ------- | --------------- |
| Radius  | 0-20px          |
| Color   | Match your site |
| Shadow  | Subtle depth    |

## Step 4: Behavior Settings

### Voice

Enable text-to-speech:

* Toggle on/off
* Affects credit usage

### Typing Animation

Show typing indicator:

* Creates natural feel
* Adjustable speed

### Memory Mode

| Mode           | Description             |
| -------------- | ----------------------- |
| **Session**    | Resets on page refresh  |
| **Persistent** | Remembers across visits |

### Safe Mode

Content filtering:

* Enable for public sites
* Blocks inappropriate content

## Step 5: Access Control

### Allowed Domains

Restrict where embed works:

```
example.com
*.example.com
subdomain.example.com
```

Leave empty for any domain.

### Public Access

| Setting        | Effect               |
| -------------- | -------------------- |
| **Public**     | Anyone can use       |
| **Restricted** | Only allowed domains |

### Rate Limiting

Prevent abuse:

* Messages per minute
* Messages per session
* Daily limits

## Step 6: Generate Code

### Choose Format

#### iframe (Recommended)

Simplest integration:

```html
<iframe
  src="https://studio.meganova.ai/embed/abc123"
  width="400"
  height="600"
  frameborder="0"
  allow="microphone"
></iframe>
```

#### JavaScript

More flexibility:

```html
<div id="meganova-chat"></div>
<script src="https://studio.meganova.ai/embed.js"></script>
<script>
  MegaNova.init({
    container: 'meganova-chat',
    characterId: 'abc123',
    theme: 'dark',
    width: 400,
    height: 600
  });
</script>
```

#### React Component

For React applications:

```jsx
import { MegaNovaEmbed } from '@meganova/react';

function App() {
  return (
    <MegaNovaEmbed
      characterId="abc123"
      theme="dark"
      width={400}
      height={600}
    />
  );
}
```

### Copy Code

1. Select format tab
2. Click **Copy Code**
3. Code copied to clipboard

## Step 7: Deploy

### Website Integration

1. Paste code into your HTML
2. Position as desired
3. Test functionality

### Verification

After deployment:

1. Load your page
2. Test the chatbot
3. Send test messages
4. Verify responses

## Common Integrations

### WordPress

Add to page/post:

1. Add HTML block
2. Paste iframe code
3. Publish

### Squarespace

1. Add Code block
2. Paste code
3. Apply changes

### Webflow

1. Add Embed component
2. Paste code
3. Publish

### Custom Sites

1. Add to HTML file
2. Or include in template
3. Deploy changes

## Troubleshooting

### Widget not loading

**Check:**

* Code pasted correctly
* Character ID valid
* Domain allowed

### CORS errors

**Solution:**

* Add your domain to allowed list
* Or enable public access

### Widget too small/large

**Fix:**

* Adjust dimensions in code
* Use responsive settings

## See Also

* [Customization](https://docs.meganova.ai/character-studio/embed-widgets/customization.md) — Advanced options
* [Embed Overview](https://docs.meganova.ai/character-studio/embed-widgets.md) — Introduction
* [API Integration](https://docs.meganova.ai/character-studio/advanced/api-integration.md) — Advanced usage
