Blueprint by Tiny
Return to
Return to Tiny.cloudTry TinyMCE for Free
Search by

Setting up PowerPaste for Google Docs

Joe Robinson

September 1st, 2021

Written by

Joe Robinson

Artwork by

Mel Poole

One of the largest obstacles when writing content inside Google Docs is copy and paste.

Even when exporting the HTML, classes and styles remain in the document. So you can write a script to automatically remove the styles and classes, and format the output so it’s readable. But something that automates the process, so that you don’t need to spend your time and energy working out a solution, would be ideal.

Initially, we started using our PowerPaste plugin internally – for copying content from GoogleDocs. However, having to use a text editor like Visual Code to remove the styling took additional time, energy and extra concentration. Setting PowerPaste to automatically check for and remove Google Docs formatting and in line styling saves our team time and energy when writing content to be published here on Blueprint, as an example.

We’ve already mentioned the improvements made in the TinyMCE 5.8 release to handle Google Docs Formatting. But this article walks you through how PowerPaste with Google Doc import is actually configured, and what to expect when using it for copy-paste tasks.

TinyMCE rich text editor HTML for PowerPaste

Here’s one example of how to set up your rich text editor HTML with TinyMCE to use PowerPaste and GoogleDocs import: 

selector : "#mytextarea",
width: 600,
height: 700,

plugins: [
//take out the "paste" plugin first if you're self hosting TinyMCE
"code", //change to advcode if it fits your project

toolbar: "code ", //or "advcode" if it fits your project
powerpaste_googledocs_import: "prompt", //Powerpaste will ask how you want to import Googledocs content
paste_tab_spaces: "4", //for any tabs, this converts them to four white spaces - useful for source code
spellchecker_active: true,
spellchecker_language: "en_US", //useful if you write in en_AU or GB, but publish for US audiences

Here’s a few additional plugins that pair well with PowerPaste when it’s configured for Google Docs copy and paste:

Code, or Advanced Code

Opening the Code or Advanced Code dialog box shows the HTML source code behind the rich text editor content. This way, you can confirm that PowerPaste has removed any style attributes attached to the tags.

TinyMCE SpellChecker

This is useful for checking spelling when you’re copying from one language format to another. For instance, if you write your content in British English, but you publish in American English, configuring the spell checker to automatically detect the different spellings is a useful PowerPaste addition. It can make preparing text for publication much easier.

What happens when you configure the prompt option

This depends on how the powerpaste_googledocs_import option is configured. The default value is the prompt string.

When activated, and you copy and paste content into the editor area, a dialog box gives you the option of keeping the Google Doc formatting, or removing it. 

To demonstrate, here’s an example Google Doc:

An image of a sample Google Doc showing tables

And here is what happens when pasting and removing formatting:

Copy and paste content from a Google Doc sample showing the inline styles removed and replaced with a new style

Finally, here is what happens if you keep the formatting intact:

Copy and pasted content from a Google Doc sample showing the inline style and formatting retained from Google Docs.

When removed, the formatting changed to match the rich text editor style. This is the behavior to expect when you configure the prompt option. The other options available are:

  1. clean: automatically removes Google Doc formatting, replacing it with a matching HTML structure, and the paste destinations style. This does not maintain any inline formatting.

  2. merge: preserves the inline formatting, but removes any style attributes from the HTML, ensuring the structure matches the original formatting as closely as possible. 

What’s next for your rich text editor HTML?

Since PowerPaste is a premium plugin, you can sign up for an API key to try out the plugin for FREE, for 14 days.

We also have a demo available for testing the PowerPaste plugin on our website. You can test the prompt configuration to explore how formatting and style is preserved, or removed with PowerPaste. Reach out to us if you have any questions or ideas about how PowerPaste can help you manage content from Google Docs sources.

HTMLContent marketing
byJoe Robinson

Technical and creative writer, editor, and a TinyMCE advocate. An enthusiast for teamwork, open source software projects, and baking. Can often be found puzzling over obscure history, cryptic words, and lucid writing.

Related Articles

  • How-to Use TinyMCE

    How to set up a CMS with Self-Hosted and Cloud TinyMCE

    by Joe Robinson in How-to Use TinyMCE
Subscribe for the latest insights served straight to your inbox every month.

Deploy TinyMCE in just 6 lines of code

Built to scale. Developed in open source. Designed to innovate.

Begin with your FREE API Key
Tiny Editor
Tiny logo
Privacy Policy - Terms of Use© 2022 Tiny Technologies Inc.TinyMCE® and Tiny® are registered trademarks of Tiny Technologies, Inc.


  • TinyMCE
  • Tiny Drive
  • Customer Stories
  • Pricing