Envira Gallery Blog

Digital Photography Tips, Tutorials and Resources

How to Integrate Google Drive with Your WordPress Media Library

How to Integrate Google Drive with Your WordPress Media Library

Last updated on Jan 15, 2025 by Southie Williamson Reader Disclosure

Are you struggling to manage the growing collection of images and media files on your WordPress website? As your site grows, so does your media library—and with it, concerns about organization and backups. Many businesses prefer to use a cloud solution like Google Drive to manage their files and media, as it offers much better features for organization and collaboration.

However, having to go back and forth between your Google Drive and WordPress Media Library all the time can be time-consuming and annoying. Luckily, that’s where a Google Drive integration comes in—offering a streamlined solution to display Google Drive images on your website.

As an expert in WordPress galleries, we’ve helped thousands of website owners handle their digital assets. In this comprehensive guide, we’ll show you how to connect Google Drive to your WordPress Media Library, depending on your needs.

Benefits of Using a Google Drive Integration with WordPress

  • Improved Organization: With Google Drive, you can create folder hierarchies, use labels, and implement better file management systems, making it easier to find and use your files.
  • Enhanced Collaboration: If you work with a team, Google Drive makes it simple to share files and collaborate on content. Team members can upload images to shared folders that automatically sync with your WordPress site.
  • Unlimited Storage Space: Google Drive offers generous storage space starting with 15GB free and affordable upgrades for more capacity. This means you can store high-quality images without worrying about space constraints.
  • Reliable Backup Solution: By storing your media files in Google Drive, you automatically get cloud backup protection. If anything happens to your WordPress site, your media files remain safe and accessible.

Method 1: Auto-Sync Google Drive with Your WordPress Media Library

Prerequisites:
– Google Drive account
– WordPress website
– WP Media Folder with Cloud Addon (premium plugin)

If you’re looking for a seamless two-way sync between WordPress and Google Drive, WP Media Folder provides the easiest, most robust solution. The plugin transforms your WordPress media library into an intuitive file manager with folder hierarchies, while the Cloud Addon automatically connects it to Google Drive in a few clicks.

JoomUnited WP Media Folder Google Drive Integration

This method automatically syncs any changes you make in either location, ensuring your media files stay organized and backed up. When you upload an image to WordPress, it’s automatically backed up to Google Drive, and when you add files to your connected Google Drive folders, they appear in your WordPress media library.

Step 1: Install the WP Media Folder Plugin

After you purchase the JoomUnited WP Media Folder with Cloud Addon, you need to install and activate the main plugin on your site:

  • Download the WP Media Folder plugin from your JoomUnited account.
  • Go to your WordPress dashboard and navigate to Plugins » Add New Plugin.
  • Click the Upload Plugin button at the top of the page
  • Upload the plugin ZIP file and click Install Now.
  • After installation completes, click Activate Plugin.

When the plugin finishes activating, you’ll arrive at the setup wizard. Go ahead and click the button that says Continue to environment check.

WP Media Library setup wizard

After that, Continue through the setup wizard, where you can configure certain features. For most users, we recommend leaving the default settings enabled.

On the final page, you’ll see a success message, and you can press Go to Media Library.

WP Media Library setup wizard success message

Step 2: Activate the Cloud Addon and Connect Google Drive

With the main plugin installed, now you’ll set up the Google Drive connection. First, you need to install and activate the Cloud Addon the same way you installed the main plugin.

After it’s activated, go to Settings » General in your WP Admin menu, scroll to the section titled Joomunited live updates, and press Link my Joomunited account.

WP Settings - Link my JoomUnited account

You’ll see a popup where you’ll enter the email and password to log into your JoomUnited account. When you’re finished, press Save Changes on the Settings page.

Now it’s time to connect your Google Drive to your WordPress Media Library. First, go to Settings » WP Media Folder, and select Cloud » Google Drive from the menu on the left.

From there, make sure the Connecting mode is set to Automatic. Then, press the Connect Google Drive button and follow the prompts to log in and authorize the connection.

Connect Google Drive with your WordPress Media Library

Step 3: Organize Your Google Drive Images in WordPress

Once connected, you can go to Media » Library in your WordPress dashboard to start managing your files. Right off the bat, you’ll notice the new folder structure and a Google Drive option in the menu.

Google Drive WordPress Media Library

You can now access all the images stored in your Google Drive directly from your WordPress dashboard. Easily filter, sort, or display additional file types using the toolbar buttons.

Filtering Google Drive images in the WordPress Media Library with WP Media Folder

To stay organized, you can create new folders directly from WordPress, and any changes you make will automatically sync with your connected Google Drive account. To set up a new folder, click the Add New Folder button.

WP Media Folder - Add new folder

A popup window will appear where you can enter a name for the folder. Once you’ve typed in the name, click Create to add the folder to your main Google Drive directory.

New new WP Media Folder

To add images to this folder, click Add New and upload a file from your computer. The uploaded image will automatically be saved to both your WordPress media library and your Google Drive. This makes it easy to manage and organize your images within WordPress without needing to access Google Drive separately.

Add new image to WP Media Google Drive folder

If you already have images in your WordPress media library, you can back them up to Google Drive by uploading them manually. Go to Media Library and find the image you’d like to back up. Simply drag and drop the image into the appropriate folder in your Google Drive, whether it’s the main folder or a subfolder.

Backup WordPress images to Google Drive with WP Media Folder

Repeat these steps to efficiently organize all your WordPress media files. You can also use the Bulk Select button to move multiple photos at a time.

Pro Tip: Create a dedicated folder structure in Google Drive for your WordPress media to keep everything organized. For example, you might have separate folders for blog posts, products, and portfolio images.

Step 4: Display Google Drive Images on Your Website

Adding Google Drive images to your content is just as simple as using regular media files. In the WordPress content editor, insert an Image block where you want the image to appear.

post edit wordpress -insert image

Click the Media Library button to open the library.

Default image block in WordPress

From there, select Google Drive or navigate to any folder within your Google Drive. Once you’ve selected a folder, you’ll see all the available media files. Simply choose the image you want to use.

Display Google Drive images on website with WP Media Folder

After selecting the image, you can add alt text, tags, image captions, and other details just as you would with any WordPress image. When everything is set, click Select, and the image will be added to your WordPress page or post via WP Media Folder.

All images are automatically optimized and served from your WordPress site, maintaining good performance while keeping your files backed up in Google Drive.

Method 2 (Free): View, Manage, and Embed Google Drive Files in WordPress

Prerequisites
– Google Drive account
– WordPress website
– Integrate Google Drive (free plugin)

If you’re looking for a free solution to access and display Google Drive content on your WordPress site, the Integrate Google Drive plugin offers a straightforward approach.

Integrate Google Drive plugin

The free plugin doesn’t include automatic syncing with the WordPress Media Library. However, it’s a good option for users who want to embed documents, create download links, or host website images on Google Drive and display them in a simple website gallery.

Step 1: Install the Free Integrate Google Drive Plugin

To begin, head to your WordPress dashboard and navigate to Plugins » Add New Plugin. Search for Integrate Google Drive, and you’ll see the plugin by SoftLab. Click Install Now, followed by Activate when the button changes.

install the Integrate Google Drive plugin

Once activated, you’ll notice a new Google Drive menu item in your WordPress dashboard. This is where you’ll manage all your Google Drive connections and view your files.

Step 2: Connect Your Google Account

Setting up the connection between WordPress and Google Drive is straightforward. Navigate to Google Drive » Settings in your WordPress dashboard. Set the Connection Type to Automatic and click the Add New Account button.

Integrate Google Drive with WordPress - Add new account

In the popups that follow, follow the prompts to log in and grant the plugin access to your Google Drive files. When finished, you’ll see your new Google Drive connection listed, and you should press Save Changes at the top.

Integrate Google Drive plugin - Settings

Step 3: View and Embed Google Drive Files on WordPress

With the connection established, you can now easily work with your Google Drive files directly from WordPress. Click Google Drive » File Browser to view and manage all your files.

The File Browser essentially offers a convenient API shortcut to your Google Drive interface. Nothing is transferred or copied to your website server, but you can upload, download, organize, and view Google Drive files without leaving WordPress.

Google Drive File Browser in WordPress

The free plugin also offers several ways to use the files that are hosted on Google Drive on your website:

  • Embed Documents: Embeds Google Drive files directly into your page or post.
  • Download Links: Allows users to directly download any file from your Google Drive account.
  • View Links: Lets users view files from your Google Drive account.
  • Gallery: Displays Google Drive images and videos in a simple gallery that’s auto-generated from your chosen folder.

You can add files in one of the ways listed above, by either building a shortcode or using the block editor. Regardless of which method you use, you MUST set correct permissions for the files in Google Drive first. For example, if you’re adding view links, all the files must be set to public.

Build a Shortcode to Embed Files

To start, click Shortcode Builder from the menu and then Add New Shortcode.

Google Drive shortcut builder for WordPress

From here, you can see all the available ways to display your files. At the top, you can give your new shortcode a title for easy reference.

embed Google Drive files in WordPress - shortcut builder

After selecting the method you want to use, hit Next. The builder will guide you through the next steps where you can:

  • Select the files or folders to use (Source)
  • Exclude certain files based on their name or extension (Filter)
  • Configure display options (Advanced)
  • Set visibility to logged-in users or require a password (Notifications)

On the last step, when you’re finished building your shortcode, click Finish. Now, you’ll see the new shortcode that you can copy and insert anywhere on your site.

Embed Google Drive files - shortcode

Embed Files in the WordPress Editor

Alternatively, if you want to embed Google Drive files from the WordPress editor, open the page or post you want to edit. Then, you can add one of the available blocks from the Integrate Google Drive plugin (Gallery, Embed Documents, Insert Download Links, or Insert View Links).

Insert WordPress block from Integrate Google Drive plugin

After choosing the block you want to use, click the Configure button inside the block.

Google Drive block - Insert view links

This will open a popup where you can select the Google Drive files you want to use and configure other settings. Click Done when you’re finished.

Now, you’ll see a preview of the files you inserted (we used view links, but it’ll display whatever block style you selected).

Google Drive view links in WordPress

Pro Tip: View and Download links will appear as the file names, so set the names you want displayed on the frontend before adding them as links.

As you can see, this Google Drive integration isn’t nearly as robust or streamlined as WP Media Folder. However, it’s a handy tool if you’re constantly switching between WordPress and Google Drive or just need a quick way to embed or link files that are hosted on your drive.

While the previous methods focus on direct Google Drive integration, Envira Gallery offers powerful features for creating stunning galleries on WordPress.

Envira Gallery Home

Envira Gallery, you can easily import images and build galleries from a variety of sources, including:

Plus, the plugin offers beautiful layouts and tons of other advanced features, such as client proofing, image tagging, filterable galleries, albums for organization, image compression, watermarking, commenting on photos, built-in AI image generation, and lots more!

Get Envira Gallery Today!

Integrating Google Drive with your WordPress media library can significantly improve your website’s media management. Whether you choose comprehensive syncing capabilities, straightforward file embedding, or Envira Gallery to bulk import ZIP files from Google Drive, you’ll benefit from better organization and a more efficient workflow.

Further Reading

We hope you enjoyed learning how to connect Google Drive with WordPress! Have a preferred method that we didn’t cover? Let us know in the comments below.

Not using Envira Gallery? Get started today!

Don’t forget to check out our blog and follow us on X (Twitter) for the best photography tips, resources, and WordPress tutorials.

Using WordPress and want to get Envira Gallery free?

Envira Gallery helps photographers create beautiful photo and video galleries in just a few clicks so that they can showcase and sell their work.

Comments

  1. Hi!
    Thanks for your useful tutorial! Whenever I try to add Google Drive files, an error occurs: invalid_client no registered login. I checked the client ID but could not find a problem. What did I do wrong?

    Thanks!

  2. do the 2 mb file size limit applies while transfering files from google drive…..Please reply

    1. Hey Paresh, the basic WordPress settings like file size limit will remain same when you import images from external resources. 🙂

  3. is the image just embed format in wordpress or after add my image with this way automatic host in my wordpress.
    what different with uload in default why, i hope use this way for reduce my hosting usage

Add a Comment

We're glad you have chosen to leave a comment. Please keep in mind that all comments are moderated according to our privacy policy, and all links are nofollow. Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.