How to Merge PDF URLs with Google Apps Script and PDF.co

Sep 2, 2024·6 Minutes Read

Welcome to our tutorial on how to easily merge multiple PDFs from URLs using Google Apps Script and PDF.co. In this guide, we will walk you through the step-by-step process of combining PDF documents from various sources into a single file. Whether you’re a business professional, a student, or just someone looking to streamline their workflow, this tutorial will show you how to accomplish this task quickly and efficiently.

So, let’s proceed. We will show you how to merge PDF URLs using Google Apps Script and PDF.co.

We will use two-sample PDFs in this tutorial. You may use a document of your choice.

Step 1: Open Google Sheets App

  • To begin. Let’s start by opening the Google Sheets app.
  • Next, add your PDF.co API key. You can get the API key in your PDF.co dashboard
  • Then, input the PDF URLs separated by a comma.
Open Google Sheets App

Step 2: Add App Script Extensions

  • Now, click the Extensions menu and choose the App Script option.
Add Google App Script Extensions

Step 3: Google App Script Code

Now, let’s add the source code to the app script.

  • After adding the source code, make sure to input the PDF.co API key in the "B1" cell.
  • The PDF URLs should be in the "A4" cell.
  • The Result should be in the "B4" cell.
  • Then, click on the Run button to execute the App Script and save the project.
Google App Script Code

Step 4: Finish App Script

  • Once the program was executed successfully. Let’s check the spreadsheet and merge the PDF URLs.
  • Click on the PDF.co menu and hit the CreatePDF button.
  • Then, click on the resulting URL to view the output.
Finish App Script

Step 5: Merge PDF Output

  • Here’s the output that we successfully merge into a single PDF. For more tutorials, you may visit our YouTube channel, and don’t forget to hit the subscribe button.
Merge PDF Output
Merge PDF Output

Step 6: About Google Apps Script

When you are merging PDFs from URLs, sometimes it can be a really overwhelming task. However, Google Apps Script and PDF.co make the whole process easy and smooth. By following the step-by-step guide from this tutorial, you can combine multiple PDF documents from various sources into a single PDF file.

You can be a business professional, a student, or just someone looking to streamline their workflow, this tutorial will provide you with the tools to accomplish your task.

Google Apps Script is a scripting language allowing users to customize and automate Google Apps such as Google Sheets, Docs, and Forms. With Google Apps Script, you can create macros, automate workflows, and connect different Google services to perform tasks such as sending emails, updating data, and more.

You can manipulate Google Suite data and services as well as build web apps and add-ons for Google Suite products, all without the need for a separate server. It is simple to learn for JavaScript developers and also provides a range of built-in libraries and functions, making it a powerful tool for automating and streamlining tasks.

Video Guide

Related Tutorials

See Related Tutorials