Returns everything currently in the execution log.
class Logger method .getLog()
Logger is the Apps Script service.
.getLog() is the method name you will see after a dot in your code.
What it does
Why it's used
- Read everything logged so far in this execution.
- Bundle logs into an error email or support ticket.
Common errors
- Forgetting parentheses on getLog. Write Logger.getLog(), not Logger.getLog or getLog by itself.
- Skipping dots between chained calls. Each step needs a dot, like Logger.getLog().
- Adding spaces where they do not belong. Write Logger.getLog(), not Logger .getLog(), Logger.getLog (), or Logger . getLog().
- Wrong capitalization. Use Logger and getLog, not logger or getlog.
Explore
Related methods
More Apps Script
Better Sheets tutorials
No tagged tutorials yet. Fetch Apps Script from the harvest table and this page fills automatically.
Related blog posts
Written guides about Logger.getLog().
What's Better Than Google Sheets?
Nothing is better than Google Sheets. You just need to learn more about the unlimited power of Google Sheets. Functions, Formulas, Apps Script and more.
Read post →How to Send Google Forms Entries Automatically with Apps Script
Google Forms provides basic email notifications for form submissions, but enhancing these notifications with detailed summaries can significantly improve productivity and response management.
Read post →Explore Coding in Google Sheets
Did you know you can actually code in Google Sheets?
Read post →