# AI Chat Bot Schedule

**URL:** <https://community.elfsight.com/t/ai-chat-bot-schedule/139544>\
**Category:** AI Chatbot\
**Tags:** Released\
**Created:** [September 10, 2025, 6:33pm UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544 "2025-09-10T18:33:47Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cameron\_Tranter](https://avatars.discourse-cdn.com/v4/letter/c/50afbb/32.png) [@Cameron\_Tranter](https://community.elfsight.com/u/Cameron_Tranter)\
**Post date:** [September 10, 2025, 6:33pm UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/1 "2025-09-10T18:33:47Z")

</div>

Could we get a feature to where we can set up a schedule for AI Chat Bot to be active/inactive? At my company, during work hours, we have a Live Chat feature but at the end of business hours, it would be nice to have AI Chat Bot active.

---

<div class="post-metadata">

**Author:** ![Max](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/max/32/710_2.png) [@Max](https://community.elfsight.com/u/Max)\
**Post date:** [September 11, 2025, 11:42am UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/2 "2025-09-11T11:42:29Z")

</div>

Greetings and welcome to the Community, @Cameron_Tranter 👋

This is a great idea, thanks for sharing! We’ll try to think about it in the future, especially if more users upvote it 🙂

The only workaround at the moment is to manually show/hide the widget on the website using the button in the dashboard:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/a/f/aff968d96cdcbf4fc39f13c6adb9a105aa612785.png)

---

<div class="post-metadata">

**Author:** ![Paul\_D](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/paul_d/32/71908_2.png) [@Paul\_D](https://community.elfsight.com/u/Paul_D)\
**Post date:** [September 11, 2025, 3:08pm UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/3 "2025-09-11T15:08:54Z")

</div>

This is an excellent idea — hopefully it gets lots of upvotes!

---

<div class="post-metadata">

**Author:** ![Jordan\_Knicely](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/jordan_knicely/32/84695_2.png) [@Jordan\_Knicely](https://community.elfsight.com/u/Jordan_Knicely)\
**Post date:** [December 2, 2025, 8:24am UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/4 "2025-12-02T08:24:16Z")

</div>

I only want the AI bot responding when we are out of office. Can you make it so we can set the hours that this widget will display on the website similar to how the Whatsapp widget works?

---

<div class="post-metadata">

**Author:** ![Max](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/max/32/710_2.png) [@Max](https://community.elfsight.com/u/Max)\
**Post date:** [December 2, 2025, 1:56pm UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/5 "2025-12-02T13:56:23Z")

</div>

Hey there, @Jordan_Knicely 👋

Many thanks for the feedback!

We already have a request for the schedule feature. I’ve moved your comment to the related thread, where we’ll keep you updated 🙂

---

<div class="post-metadata">

**Author:** ![Max](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/max/32/710_2.png) [@Max](https://community.elfsight.com/u/Max)\
**Post date:** [March 4, 2026, 2:34pm UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/6 "2026-03-04T14:34:24Z")

</div>

Hey everyone!

Our devs came up with a custom solution to set a schedule for the chatbot display:

```auto
const WIDGET_ID = 'WIDGET_ID';
const IS_PORTAL = true;
const TARGET_TIMEZONE = 'Europe/Rome'; // IANA Time Zone Database
const CHECK_INTERVAL = 1; // Minutes
// 1–7 (1 = Monday, 7 = Sunday)
const SCHEDULE = {
  1: {
    start: '21:00',
    end: '11:00'
  },
  2: {
    start: '21:00',
    end: '11:00'
  },
  3: {
    start: '21:00',
    end: '11:00'
  },
  4: {
    start: '21:00',
    end: '11:00'
  },
  5: {
    start: '21:00',
    end: '11:00'
  },
  6: {
    start: '21:00',
    end: '11:00'
  },
  7: {
    start: '21:00',
    end: '11:00'
  },
};
const getNowInTargetTZ = () => {
  const tzString = new Date().toLocaleString('en-US', {
    timeZone: TARGET_TIMEZONE,
  });
  return new Date(tzString);
};
const parseTimeToMinutes = (time) => {
  const [h, m] = time.split(':').map(Number);
  return h * 60 + m;
};
const checkShift = (dayIndex, nowMinutes, isYesterday) => {
  const schedule = SCHEDULE[dayIndex];
  if (!schedule) {
    return false;
  }
  const start = parseTimeToMinutes(schedule.start);
  const end = parseTimeToMinutes(schedule.end);
  if (start <= end) {
    return !isYesterday && nowMinutes >= start && nowMinutes <= end;
  } else {
    return isYesterday ? nowMinutes <= end : nowMinutes >= start;
  }
};
const isNowInSchedule = () => {
  const now = getNowInTargetTZ();
  const currentDay = now.getDay() === 0 ? 7 : now.getDay();
  const previousDay = currentDay === 1 ? 7 : currentDay - 1;
  const nowMinutes = now.getHours() * 60 + now.getMinutes();
  return (
    checkShift(currentDay, nowMinutes, false) ||
    checkShift(previousDay, nowMinutes, true)
  );
};
const updateVisibility = (widgetContainer) => {
  widgetContainer.style.display = isNowInSchedule() ? '' : 'none';
};
const addSchedule = () => {
  const widgetContainer = IS_PORTAL ?
    document.body.querySelector(`.es-portal-root[class*="${WIDGET_ID}"]`) :
    document.body.querySelector(`.es-embed-root[class*="${WIDGET_ID}"]`);
  if (!widgetContainer) {
    setTimeout(addSchedule, 250);
    return;
  }
  updateVisibility(widgetContainer);
  setInterval(
    () => updateVisibility(widgetContainer),
    CHECK_INTERVAL * 60 * 1000
  );
};
addSchedule();

```

  

In this script you should replace the following values:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/b/c/bc8354b7a6799ad3e5452d502ca827a93d04cabd.png)

`WIDGET_ID` — Replace with the [ID of your widget](https://help.elfsight.com/article/1219-where-to-get-your-widget-id-in-new-dashboard).

`IS_PORTAL` — `true` if the widget is **Floating** , otherwise `false` .

`TARGET_TIMEZONE` — the timezone of the schedule in the format ‘Europe/Rome’.

`CHECK_INTERVAL` — the frequency of checking the current time.

`SCHEDULE` — the schedule. The numbers represent the days of the week: from 1 (Monday) to 7 (Sunday). For example, here are the working hours on Monday:

```auto
1: {
    start: '21:00',
    end: '11:00'
  },

```

If a day is a _“day off”_ , it should simply be removed from the schedule.

---

<div class="post-metadata">

**Author:** ![Max](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/max/32/710_2.png) [@Max](https://community.elfsight.com/u/Max)\
**Post date:** [April 3, 2026, 11:00am UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/7 "2026-04-03T11:00:48Z")

</div>

Update: the feature is now in the works! 🎉

It’s currently on the **Design** stage, but we’ll keep you updated on the progress here 😊

---

<div class="post-metadata">

**Author:** ![Max](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/max/32/710_2.png) [@Max](https://community.elfsight.com/u/Max)\
**Post date:** [July 17, 2026, 2:29pm UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/14 "2026-07-17T14:29:44Z")

</div>

Update: the feature moved to the **Development** stage!

---

<div class="post-metadata">

**Author:** ![Max](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/max/32/710_2.png) [@Max](https://community.elfsight.com/u/Max)\
**Post date:** [September 1, 2026, 2:28pm UTC](https://community.elfsight.com/t/ai-chat-bot-schedule/139544/15 "2026-09-01T14:28:43Z")

</div>

Hey everyone!

Great news — the schedule option is already available! 🎉

Find more details in this post: [AI Chatbot: Control when your chatbot should appear on your website](https://community.elfsight.com/t/ai-chatbot-control-when-your-chatbot-is-visible-on-your-website/173209)
