Embedding the Simple Donation Widget on a Wix site

Follow the steps below to embed the simple widget on your Wix site.

  1. In the Nonprofit Admin Portal, click the "Widget" tab in the menu on the top of the dashboard.
  2. You'll see a preview of your widget below.
  3. Next, associate your widget with one of your customized fundraising pages. The widget will adopt your campaign’s styling and donation frequency. In addition, donations from the widget will be associated with this fundraising page in data you get from our platform.
  4. Edit donation amount options included on your widget. You can choose to include default suggested donation amount buttons ($25, $50, $100, $250), come up with your own four suggested amount options, or set one pre-filled amount for the custom donation field.
  5. Click "Get Embed Code" then select and copy the code in its entirety.
  6. Click here and follow the instructions provided by Wix.
  7. When editing your page, click the "Home Page Code" footer, which will bring up an HTML code editor. You should, by default, see the following code (if you have never edited this section before):$w.onReady(function () {
  8.    //TODO: write your page related code here...
  9. Delete that code and paste in the following:

const GL_WIDGET_ID = "#html1";

import wixWindow from 'wix-window';

$w.onReady(function () {

   const glWidget = $w(GL_WIDGET_ID);


   glWidget.onMessage((event) => {

       if (event.data === "is_wix") {


       } else {

           const matches = event.data.match(/^wix:open_modal:(.*)$/);

           if (matches) {

               wixWindow.openModal(`${matches[1]}&show_close_button=false`, {

                   "width": 500,

                   "height": 650






9. If you've already embedded one widget on your Wix site, you will need to replace "html1" (highlighted in bold above).

If you have any problems embedding the widget on your site, contact us at support@givelively.org.

November 26, 2018