# Need help rewrite Velo code to embed Voiceflow to an element

**URL:** <https://forum.wixstudio.com/t/need-help-rewrite-velo-code-to-embed-voiceflow-to-an-element/64888>\
**Category:** Ask the community\
**Tags:** question, code, wix-studio\
**Created:** [November 20, 2024, 7:35pm UTC](https://forum.wixstudio.com/t/need-help-rewrite-velo-code-to-embed-voiceflow-to-an-element/64888 "2024-11-20T19:35:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Matthew\_Boettcher](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/matthew_boettcher/32/100286_2.png) [@Matthew\_Boettcher](https://forum.wixstudio.com/u/Matthew_Boettcher)\
**Post date:** [November 20, 2024, 7:35pm UTC](https://forum.wixstudio.com/t/need-help-rewrite-velo-code-to-embed-voiceflow-to-an-element/64888/1 "2024-11-20T19:35:25Z")

</div>

I’m attempting to use the embed method for putting a Voiceflow webchat into a container on a Wix web page, instead of the bottom-right icon method

This method is described here: [Embed and customize styling](https://docs.voiceflow.com/docs/embed-customize-styling)  
and shown here: [https://youtu.be/2gy-0HURFI0?si=sD2sliHF-B4eaCeN](https://youtu.be/2gy-0HURFI0?si=sD2sliHF-B4eaCeN)

The code provided by Voiceflow makes use of the “window” and “document” objects, which as I understand cannot be directly accessed by Velo custom code.

Would anyone be able to show me how the Voiceflow embed code should be re-written using Velo $w code, to get this embed to work? We are using Wix Studio.

I’m evaluating Voiceflow so very much want to know if this is even possible on Wix.

Happy to work with a developer as a short paid $ engagement if can show this is capable of being done.

---

<div class="post-metadata">

**Author:** ![onemoretime](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/onemoretime/32/104023_2.png) [@onemoretime](https://forum.wixstudio.com/u/onemoretime)\
**Post date:** [November 21, 2024, 4:21pm UTC](https://forum.wixstudio.com/t/need-help-rewrite-velo-code-to-embed-voiceflow-to-an-element/64888/3 "2024-11-21T16:21:21Z")

</div>

Hi, Matthew\_Boettcher !!

Currently, using custom elements is the most flexible method to utilize `window` or `document` on Wix. However, it does require some practice. To start, you might want to try embedding it into your Wix site using an `iframe` element. I’m not very familiar with Voiceflow, but if its functionality requires access to media devices like a microphone, it’s generally difficult to achieve this with an `iframe`. In that case, implementing it with a custom element would be a better choice.

> **[Wix Editor: Adding a Custom Element to Your Site | Help Center | Wix.com](https://support.wix.com/en/article/wix-editor-adding-a-custom-element-to-your-site)**
>
> Use the custom element to add visible content to your site, and to design elements with additional CSS capabilities. In this article, read more about:
> How cus
