Automation
What happens to our automations when the person who built them leaves?
By Paul Meakin6 min read

Who does an automation actually belong to?
Not the business, unless someone made it so.
Google's guide to installable triggers is plain about it: installable triggers always run under the account of the person who created them. That is the trigger that sends the Monday report, files the form responses and chases the timesheets. It runs with that person's authorisation, even when somebody else opens the spreadsheet.
Which is fine, right up until that person hands in their notice.
If someone builds a script on a quiet afternoon and it works, it can become part of how the business runs without anyone deciding who owns it. Unless someone writes it down, the whole thing hangs off one login.
What does Google say happens to the files?
Google's guide to shared drives draws the line clearly. Shared drive files belong to the team instead of an individual. When someone leaves and an admin deletes their account, files they added or created in shared drives remain.
That protection belongs to shared drives. Files sitting in one person's own My Drive are theirs, and keeping them means moving them to a new owner before the account goes. Google's Data Transfer API exists for exactly that step: a transfer resource represents the transfer of the ownership of user data between users.
Google's page on script projects explains the two kinds of script you are likely to have. A standalone project is not attached to a file. A container bound project lives inside a Doc, Sheet, Slides file or Form. A container bound project sits inside its file, and Google says only the owner of the container can see the options to delete it. So the question of who owns the file is also the question of who controls the script.
Put those together and the risk is easy to see:
| What the automation relies on | Where it can sit | What it depends on when the owner leaves |
|---|---|---|
| The trigger | Created under one person's account | It runs under that account, so the job depends on it |
| The script | In their My Drive, or bound to a file they own | Moving it to a new owner before the account goes |
| The spreadsheet it writes to | In their My Drive | Moving it to a new owner before the account goes |
| Files in a shared drive | Owned by the organisation | Nothing: Google says these files remain |
Where does this catch businesses out?
A leaver process built around people, not jobs, can miss this.
The NCSC's guidance on identity and access management says your account management process should include a joiners, movers and leavers policy, so access can be revoked when no longer needed. That is right, but closing the account is only half of it. The checklist also needs to ask what that account was running.
If the account goes, the Monday report can stop and nobody may notice, because the person who would have noticed is the one who left.
The second trap is where the warning goes. Google says that when an installable trigger fails, no error message appears on your screen. Instead Apps Script sends a failure email. Worth knowing whose inbox that is, and whether it still exists. Google adds that the email includes a link to deactivate or reconfigure the trigger, which is useful to whoever reads it.
What is the fix?
Make the business the owner, before anyone leaves. In practice that comes down to four habits.
Keep the files an automation depends on in a shared drive. Google says your organisation owns the files in a shared drive, not an individual, and that they stay when someone leaves. That covers the spreadsheet the script writes to, the template it copies and the folder it files into.
Run important triggers from an account the business controls, not from whoever happened to build them. Because a trigger runs under the account that created it, the choice of account is the choice of owner. Decide it on purpose. The NCSC also says to review user accounts and systems for unnecessary privileges on a regular basis. Whichever account runs your automations belongs in that review, so you know what it can reach and who looks after it.
Write the automations down. A one page list will do: what each job does, when it runs, which account runs it, which files it touches and who to tell when it breaks. The NCSC's guidance adds that you should be able to associate all actions in the system to the person or account that performed them. A list of what runs under which account is the start of that.
Add the automations to the leaver checklist. Before an account is closed, check what it owns and what it runs, then move it to a shared drive or a new owner.
| Habit | What it protects | When to do it |
|---|---|---|
| Files in a shared drive | The data the script reads and writes | When the automation is built |
| Triggers on a business owned account | The schedule itself | When the automation is built |
| A one page list of automations | Knowing what exists at all | Now, then whenever one is added |
| Automations on the leaver checklist | Anything missed above | Before the account is suspended or deleted |
None of this is clever. It is the boring bit that is easy to skip on the afternoon the script first works.
When is this not the answer?
If the business has a handful of small personal shortcuts, such as one person's email filters or a script that only tidies their own inbox, there is nothing to rescue. Let them go with the account.
If the automations have grown into something the business genuinely cannot run without, a shared drive and a list may not be enough. At that point it is worth asking whether the job belongs in a proper system with its own support, rather than in a script one person understood. Our post on stopping people breaking the shared spreadsheet covers the same problem from the spreadsheet side.
And if you are dealing with a leaver right now, start with access. Our post on getting a new starter working on their first day runs the same list backwards for leavers. Then come back to the automations before the account is deleted, not after.
Where do you start?
Ask this week what would stop if the person who built your scripts left tomorrow. If nobody can answer in a minute, that is the answer.
Then write the list. Every automation, who it runs as, what it touches. Keep it short enough that someone will actually read it.
If the list turns up more than you expected, tell us what's stuck and we'll map the quickest fix. We will move what needs moving, put the owners on business accounts and leave you with a list someone else can read. Time to talk yet?
Common questions
Do files in a shared drive stay when someone leaves?
Yes. Google says that when someone leaves and an admin deletes their account, files they added or created in shared drives remain.
Can a trigger run as someone other than the person who made it?
Not an installable trigger. Google says installable triggers always run under the account of the person who created them, so the person who sets it up decides whose account it depends on.
Who can delete a script that is bound to a spreadsheet?
Google says only the owner of the container can see the deletion menu options, and that a deleted container bound project cannot be recovered.
Is a list of automations really worth the effort?
The NCSC says you should be able to associate all actions in the system to the person or account that performed them. A list of what runs under which account is a simple start on that.
Sources
Paul Meakin, Founder
Twenty years of fixing businesses from the inside, eighteen of them in recruitment from consultant to national operations, before building the automation, web applications and compliance systems Staxxd runs today.
More about Paul