Daily
Block focus time on busy days
On days full of meetings, a focus block is added to your first free gap.
- Runs
- Daily
- Apps
- Google Calendar
- AI
- Not needed
- Access
- read+write
Send this to your assistant
Create a ClickRuntime automation: every evening at 8pm, if tomorrow has more than 4 hours of meetings, add a 2-hour Focus block marked busy in the first free gap.
First time? Adding ClickRuntime to your assistant takes about two minutes.
Why use it
Why teams use this automation
A product manager's Tuesday looks fine on Monday night, then fills with six meetings by morning. The week's real work, specs and reviews, gets squeezed to the edges or pushed to evenings. Nobody schedules over blocked time, but she never remembers to block it until the day is already full, and by then every open slot has an invitation sitting on it.
Each day, ClickRuntime looks at tomorrow's Google Calendar events and adds up the meeting time. If the day is heavy, it finds a free gap and creates a busy focus event, so that colleagues and booking tools see you as unavailable. Lighter days are left untouched. Nothing changes on days that are not overloaded.
Engineers and writers who need long unbroken stretches use it to protect them before the invitations arrive.
What you get out of it
Deep work gets a protected slot
A busy event on the calendar stops other people from booking over it. Hours for writing and thinking survive on exactly the days when they would otherwise disappear. Specs, reviews and planning get done during working hours rather than at the weekend.
Heavy days get relief automatically
The automation only acts when meeting time passes your limit. Light days stay open for spontaneous conversations, so you are not hiding on days when you have capacity. Flexible days stay flexible.
Fewer evenings spent catching up
When work is squeezed to the edges, it spills into nights. Reserving a block during the day keeps more tasks inside working hours, which supports better sleep and sustainable pace. The saved evenings are the real payoff.
Colleagues see your availability honestly
Booking tools and teammates respect the busy block, which sets a clear boundary without a conversation. People simply pick another time, with no friction or awkwardness. Nobody has to decline anything or explain.
Consistent habit, no willpower needed
Blocking time works only when you do it every day. Automating it removes the dependence on remembering, which is why the habit actually survives busy weeks. Most people give up on manual blocking within a month, so removing the manual step is what makes the benefit last.
How it works
What happens, step by step
Every day ClickRuntime looks at tomorrow's events in your Google Calendar between 9am and 6pm.
It adds up how much of the day is already taken by meetings.
On a busy day it finds the longest free gap.
It books that gap as a Focus event marked busy, so nobody can schedule over it.
Before it runs live
- Connect Google Calendar
What you get
Build your own
Need it to work differently?
Your own rules
Conditions, thresholds, filters and exceptions, written the way you'd explain them to a colleague.
Any number of apps
One automation can read from one app and update several others. Over 248 apps are ready, and anything with an API works too.
AI where it helps
Summaries, classification, extraction and drafts use ClickRuntime's built-in AI, with no extra key.
On a schedule or on each event
Runs as often as every 5 minutes, or the moment an app sends an event, and keeps track of what it already handled.
Changes you can ask for
- Run it at a different time, more or less often, or only on weekdays
- Add an AI step, for example to summarize, sort or draft a reply
- Add another app, for example also send it to Slack
- Combine it with other Google Calendar steps into one automation
Under the hood
The code that runs this automation
from google.oauth2.credentials import Credentials
from googleapiclient.discovery import build
from datetime import datetime, timedelta, time
from zoneinfo import ZoneInfo
from clickruntime import on_trigger, credentials
TZ = ZoneInfo("America/New_York")
@on_trigger
def run(event):
cal = build("calendar", "v3", credentials=Credentials(credentials.connection("google", "work")), cache_discovery=False)
day = datetime.now(TZ).date() + timedelta(days=1)
start, end = datetime.combine(day, time(9), TZ), datetime.combine(day, time(18), TZ)
items = [e for e in cal.events().list(calendarId="primary", timeMin=start.isoformat(), timeMax=end.isoformat(),
singleEvents=True, orderBy="startTime").execute()["items"] if "dateTime" in e["start"]]
spans = [(datetime.fromisoformat(e["start"]["dateTime"]), datetime.fromisoformat(e["end"]["dateTime"])) for e in items]
if sum((b - a).total_seconds() for a, b in spans) <= 4 * 3600:
return {"blocked": False}
cursor = start
for a, b in spans + [(end, end)]:
if a - cursor >= timedelta(hours=2):
cal.events().insert(calendarId="primary", body={
"summary": "Focus", "transparency": "opaque",
"start": {"dateTime": cursor.isoformat()}, "end": {"dateTime": (cursor + timedelta(hours=2)).isoformat()},
}).execute()
return {"blocked": True, "at": cursor.isoformat()}
cursor = max(cursor, b)
return {"blocked": False, "reason": "no 2-hour gap"}FAQ
Common questions
How much meeting time makes a day count as busy?
How does it pick the free gap for the focus block?
Will the focus event be visible to my colleagues?
What permissions does it need?
Does it need AI?
How many runs does it use?
Can I change how it works?
Related
You might also like
Sync an outside calendar feed into Google Calendar
Events from a feed or another tool appear in your calendar and stay up to date as they change or get cancelled.
See how it worksSee who on your team is away this week
Each Monday you get a list of who is off and when, taken from your team's calendars.
See how it worksPost your team's daily agenda to Slack
Each weekday morning your team channel gets today's events from the shared calendar.
See how it worksKeep exploring
Set up “Block focus time on busy days” from your assistant
Copy the prompt above, or connect your assistant first. Free plan, no credit card.