Readers like you help support Android Police. When you make a purchase using links on our site, we may earn an affiliate commission. Read More.

As anyone that has ever tried to paste code into a document can tell you, it can be tricky. Document-writing tools like Microsoft Word and Google Docs are meant to make words and sentences readable, and while switching to a monospaced font for those bits of code would fix half of those problems, it's still far from ideal. Luckily, Google Docs is now aiming to make code easy to display within a document by adding a revolutionary new feature: code blocks.

ANDROIDPOLICE VIDEO OF THE DAY

In normal Word documents, there are plenty of workarounds to properly display a code block, but there's no such thing as a proper code block feature. In this regard, Google Docs is outdoing its Microsoft counterpart. , people writing documents on its online platform can now insert snippets of code as code blocks and have them displayed correctly within the document. This code block works as one of many "building blocks" within Docs, together with meeting notes and other features.

Google Docs Code-anim
Source:

If you want to check it out, just type out your code in the document (no matter if it looks awful) and go to Insert > Building Blocks > Code Block, and then select the programming language you've typed out. Docs will then convert the code you just wrote into a smart code block, automatically applying proper styling and colors. It's a neat feature that lets you show code as it's meant to be shown, not only making its readability easier but also making things easier for collaborators within a document as well.

The feature is now rolling out to select Google Workspace business accounts, and it might take a few weeks for it to reach everyone. Sadly, though, the blog post says that the feature won't be rolling out to Google personal accounts, so it looks like most people will be missing out on the fun. Who knows if it'll arrive in the future, though?