Author Archives: Google Developers

Announcing the 12 remarkable innovators selected for the upcoming Google for Startups Accelerator: Voice AI program

Posted by Jason Scott, Head of Startup Developer Ecosystem, USA & Saurabh Sharma, Head of Assistant Investments

Image from accelertor

In December 2020, we announced our inaugural Google for Startups Accelerator: Voice AI program, a 10-week digital accelerator designed to help North American voice technology startups to take their businesses to the next level. Today, we are proud to announce our cohort of 12 companies - collectively leveraging voice user interfaces to solve complex challenges across accessibility, education, and care:

Babbly, Toronto, Ontario, Canada

Babbly provides parents real-time insights on their child’s speech and language skills and recommends personalized activities that promote their child's development.

Bespoken, Seattle, Washington, United States

Bespoken is the leader in automated testing, training, and monitoring for voice applications and devices. If you can talk to it, Bespoken can test it!

conversationHEALTH, Toronto, Ontario, Canada

conversationHEALTH enables conversational agents for patients and healthcare professionals in clinical trials, medical affairs, and commercial lines of business.

Nēdl, Santa Monica, California, United States

nēdl is democratizing access to the microphone by giving everyone their own live call-in radio station that transcribes, amplifies, and monetizes the audio creator's words as they speak.

OTO.AI, New York, New York, United States

OTO is building an acoustic engine capable of delivering non-semantic insights (intonation, emotions, laughter,etc.) from voice streams in real-time, on a small compute footprint.

Piffle, San Francisco, California, United States

Piffle is a voice gaming platform that aims to nurture professional wellness through conversational gameplay.

Powow AI, New York, New York, United States

Powow is a SaaS platform which unleashes the power of AI in business meetings. Powow uses proprietary AI algorithms to transcribe and analyze meetings, transforming them into actionable insights.

SiMBi, Vancouver, British Columbia, Canada

SiMBi combines learners' narrations with the text of a story to create an engaging audiovisual book that learners worldwide can read along to.

Talkatoo, Halifax, Nova Scotia, Canada

Talkatoo is a dictation software explicitly designed for veterinary and medical professionals, enabling them to save time in their practice.

Tinychef, New York, New York, United States

tinychef is a voice-first Culinary AI™ platform that helps consumers in their kitchen from their dinner dilemma, to grocery planning, grocery shopping, and cooking their meals with interactive experiences on smart speakers.

Voicify, Boston, Massachusetts, United States

Voicify’s SaaS platform allows brands and large enterprises to easily design, build, and deploy voice apps, chatbots, and other conversational experiences across voice assistants, chatbots, and social media platforms.

Vowel, New York, New York, United States

Vowel brings the best of productivity and communication platforms into a single, integrated meeting tool.

The program kicks off on Monday, March 15th and will focus on product design, technical infrastructure, customer acquisition, and leadership development - granting our founders access to an expansive network of mentors, senior executives, and industry leaders,

We are incredibly excited to support this group of entrepreneurs over the next three months, connecting them with the best of our people, products, and programming to advance their companies and solutions.

We look forward to augmenting the work of these 12 innovators and to showcasing their accomplishments on Thursday, May 20th at 12:30pm EST at our Google for Startups Accelerator: Voice AI Demo Day.

These Black tech creators are changing the domain

Posted by Jermaine Robinson, Google Registry Team

Illustration of 6 developers

It’s been two years since the Google Registry team launched its #MyDomain video series, which highlights creators in tech. While we’re proud of the initiatives we’ve featured so far, we want to do a better job of representing all voices. In honor of Black History Month, we’re featuring six Black creators who are making waves in the digital space.

Dairien Boyd, #MyDomain Video

Dairien Boyd is a founding member and principal designer at All Turtles, a mission-driven product studio. He’s responsible for building experiences that are both fun and useful within mmhmm.app — a project born out of the COVID-19 pandemic. The new reality of working remotely set Dairien and his team on a path to design a better way to deliver presentations — one that works in an all-video conferencing world. They created a powerful presentation tool that provides immersive backgrounds and visual effects to help add a bit of fun to virtual meetings.

Benjamin Williams, #MyDomain Video

Benjamin Williams also found new sources of inspiration during the pandemic. A software engineer at Google by day, Williams launched floward.app — a journaling and creative writing application that encourages “imperfection” — as a way to cope with the challenges and stresses that come from being stuck at home. By providing daily thought-provoking prompts, users can get their thoughts down on “paper” within a simple UI that intentionally prevents going back and making revisions; this way, they stay in the flow of writing instead of fixating on what they’ve already written.

Rhianna Jones, #MyDomain Video

A writer and model by day, Rhianna Jones started a campaign for “Afrovisibility” as a true passion project. Her campaign, which pushes for more widespread adoption of natural hair emojis within universal keyboards (including Android and iOS), went viral. It wasn’t long before her domain — afrohairmatters.page — helped Jones connect with industry leaders. “The opportunity to collaborate only helps the culture move forward in a direction that better represents the rainbow of tech users,” Jones says. While it might seem small to some, the addition of natural hair emojis is a major step towards promoting Afrovisibility in everyone’s daily digital language and lives — especially for a younger generation that is all about ✊? ? ??‍ ?.

Michael Broughton, #MyDomain Video

Michael Broughton, CEO of Perch, launched his credit-building app after getting denied a loan to cover the remainder of his college tuition while attending the University of Southern California. “I was told to get a credit card in order to build credit, but when I applied for a credit card, they said I needed to build my credit score first,” he says. “This made me realize how difficult it can be for individuals to develop their personal finances without already having a foot in the door.” Instead of feeling defeated, he channeled his frustrations into launching getperch.app, a service that helps others build credit history and boost their credit scores.

Edward Cunningham, #MyDomain Video

Edward Cunningham is cofounder and CTO of NXSTEP.app, a platform that allows high-school seniors to connect with current college students to get deeper insights into life within the walls of various academic institutions. By connecting with currently-enrolled college students, seniors can better determine the right college for them. It’s like matchmaking for higher education: helping students decide on their future alma mater based on personality, interests, and goals.

Adesina Tyler, #MyDomain Video

Adesina Tyler is our youngest creator in this month’s #MyDomain series. Tyler is a junior in high school, juggling the complexities that come with distance learning, schoolwork and extracurricular activities. As busy as he’s been, he somehow found the time to launch wondershop.page as part of his participation in Google’s technology program, Code Next. He built his website (an online retail store) as a way to better understand the basic building blocks of e-commerce.

Videos of everyone featured above are available at goo.gle/mydomain. Ensuring proper representation of all groups is crucial for everyone in tech. We all benefit and learn from hearing the full spectrum of voices — especially the voices of those who’ve been underrepresented for far too long.

We want to actively do our part in moving the industry in the right direction by celebrating all entrepreneurs, founders and creators. If you have a unique story to share about an .app. ,dev, or .page domain and would like to be considered for our next series, please fill out this short application form and help us produce and share content that better represents all of us in an industry that still has a long way to go.

How we’re helping developers with differential privacy

Posted by Miguel Guevara, Product Manager, Privacy and Data Protection Office

At Google, we believe that innovation and privacy must go hand in hand. Earlier this month, we shared our work to keep people safe online, including our investments in leading privacy technologies such as differential privacy. Today, on Data Privacy Day, we want to share some updates on new ways we’re applying differential privacy technologies in our own products and making it more accessible to developers and businesses globally—providing them with greater access to data and insights while keeping people’s personal information private and secure.

Strengthening our core products with differential privacy

We first deployed our world-class differential privacy anonymization technology in Chrome nearly seven years ago and are continually expanding its use across our products including Google Maps and the Assistant. And as the world combats COVID-19, last year we published our COVID-19 Community Mobility Reports, which uses differential privacy to help public health officials, economists and policymakers globally as they make critical decisions for their communities while ensuring no personally identifiable information is made available at any point.

This year in the Google Play console, we’ll provide new app metrics and benchmarks to developers in a differentially private manner. When launched, developers will be able to easily access metrics related to how successfully their apps are engaging their users, such as Daily Active Users and Revenue per Active user, in a manner that helps ensure individual users cannot be identified or re-identified. By adding differential privacy to these new app metrics, we’ll provide meaningful insights to help developers improve their apps without compromising people’s privacy, or developer confidentiality. Moving forward, we plan to expand the number of metrics we provide to developers using differential privacy.

As we have in the last year, we’ll continue to make our existing differential privacy library even easier for developers to use. For example, this month we’re open sourcing a new differentially private SQL database query language extension that is used in thousands of queries done every day at Google. These queries help our analysts obtain business insights, and observe product trends. This is a step forward in democratizing privacy safe data analysis, empowering data scientists around the world to uncover powerful insights while protecting and respecting the privacy of individuals.

Partnering with OpenMined to make differential privacy more widely accessible

As we continue to make advancements with privacy-preserving technologies in our own products, it’s also important to us that developers have access to this technology. That’s why in 2019, we open-sourced our differential privacy library and made it freely accessible, easy to deploy and useful to developers globally. Since then, hundreds of developers, researchers and institutions have incorporated Google’s differential privacy algorithms into their work, enabling them to tackle new problems while using data in a responsible and privacy protective way. One of these companies is French healthcare startup Arkhn. For Arkhn, differential privacy is making it possible to pursue its mission to revolutionize the healthcare industry with artificial intelligence, enabling them to gather, query and analyze cross-department hospital data in a secure, and safe way.

To help bring our world class differential privacy library to more developer teams, like the one at Arkhn, today we’re excited to announce a new partnership with OpenMined, a group of open-source developers that is focused on taking privacy preserving technologies and expanding their usage around the world. Together with OpenMined, we will develop a version of our differential privacy library specifically for python developers. By replicating Google’s differentially private infrastructure, Python developers will have access to a new and unique way to treat their data with world-class privacy.

A collaborative approach to improving the state of privacy in Machine Learning

Two years ago, we introduced TensorFlow Privacy (GitHub), an open source library that makes it easier not only for developers to train machine-learning models with privacy, but also for researchers to advance the state of the art in machine learning with strong privacy guarantees. In the past year, we've expanded the library to include support for TensorFlow 2, as well as both the Keras Model interface and TensorFlow's premade estimators. Thanks to a collaboration with researchers from University of Waterloo, we’ve improved performance, with our new release making it four times faster or more to train on common workloads.

We also recognize that training with privacy might be expensive, or not feasible. So we set out to understand how private machine learning models are. Last year we open-sourced our attack library to help address this and help anyone using the library get a broader privacy picture of their machine models. Since then, we partnered with researchers at Princeton University, and the National University of Singapore who have added new features that expand the library’s scope to test generative models and non-neural network models. Recently, researchers at Stanford Medical School tried it on some of their models, to test for memorization. This testing helped them understand the privacy behavior of their models, something that wasn’t possible beforehand.

We’ve also published new research studying the trade-offs between differential privacy and robustness, another property at the core of AI ethics, privacy and safety.

Our work continues as we invest in world-class-privacy that provides algorithmic protections to the people who use our products while nurturing and expanding a healthy open-source ecosystem. We strongly believe that everyone globally deserves world-class privacy, and we’ll continue partnering with organizations to fulfill that mission.

Join us for #30DaysOfFlutter

Posted by Nikita Gandhi (Community Manager, GDG India), Nilay Yener (Program Manager, Flutter DevRel)

Happy New Year folks. It’s the perfect time of year to learn something new! Do you have an app idea you’ve been dreaming of over the holidays? If so, we have just the opportunity for you! Starting February 1st, leading up to our big event on March 3rd, join us for #30DaysOfFlutter to kickstart your learning journey and meet Flutter experts in the community. Whether you are building your first Flutter app or looking to improve your Flutter skills, we have curated content, code labs, and demos!

Flutter is Google’s open source UI toolkit for building beautiful, natively compiled applications for mobile, web, and desktop from a single codebase. It’s one of the fastest growing, most in-demand cross platform frameworks to learn and is used by freelance developers and large organizations around the world. Flutter uses the Dart language, so it will feel natural to many of you familiar with object-oriented languages.

Jump in, the water’s fine!

Along with the curated content, we will also have four live AskMeAnything sessions (#AMAs), where you can meet members of Google’s Flutter team and community. You can also join us on the FlutterDev Discord channel, where you can meet the other members of the community, ask and answer questions, and maybe make some new Flutter friends too!

Does this sound exciting? Visit the 30 Days of Flutter website to get more information and to register to join.

#30DaysOfFlutter Schedule

Your learning journey with Flutter for the month will look like this::

Week 1

Receive curated content to your inbox. Meet other Flutter Devs on Discord. Attend Kick Off Webinar on February 1st.

Week 2

Receive more content. Start building your first Flutter app. Join the webinar and ask your questions.

Week 3

Work on your app and attend the 3rd webinar to ask your questions.

Week 4

Complete your project and learn how to share it with the Flutter community.


Are you ready to learn one of the most in demand developer skills in the world?

Sign up to be a part of the journey and be sure to follow @FlutterDev on Twitter, to get updates about #30DaysOfFlutter.

21 websites and apps to make your 2021 better

Posted by Christina Yeh, Google Registry Team

GIF of animated person sitting at computer

Google Registry is always on the lookout for interesting websites that have launched using our top-level domains. 2020 was a rough year, so to help you make 2021 (at least a little bit) better, we’ve rounded up 21 ways you can start something .new, get .appy, turn a new .page, and make .dev(elopment) a breeze.

Start something .new:

  1. Collage.new: Looking for a new direction in 2021? Craft an inspiring vision board with BeFunky’s Collage Maker.
  2. Resume.new: If you’re looking for a new job this year, spruce up your resume with one of CV2You’s customizable templates to open the door to new career adventures.
  3. Hire.new: Hiring for new roles and jobs in 2021? With ZipRecruiter, you can post your job and reach quality candidates to join your team in no time.
  4. Site.new: Have a website you’ve been meaning to build? With easy-to-use tools and professionally designed templates, you can launch your website using Google Sites.
  5. Shopify.new: Starting a new side hustle? With Shopify’s powerful tools, anyone can quickly start a business and launch an online store.
  6. Flutter.new: Been dreaming up a great idea for an app? Get it done in the new year with Flutter, Google’s toolkit for building beautiful applications for mobile, web and desktop.

Get .app(y):

  1. Puppr.app: Do you have a new dog in your life? Get help training your furry friend with lessons, tricks, and live chat.
  2. Uhmmm.app: Fight the awkward silence in your online meetings with free elevator music.
  3. Sayana.app: Track your thoughts and feelings, get tips on coping with your emotions and talk to people in a similar life situation.
  4. Glitterly.app: Make videos with animations, effects, stock videos and images in just a few clicks.
  5. Get.reface.app: Say cheese! Use your selfies to make fun face swap videos and gifs.

Turn to the next .page:

  1. Nxt.page: Recreate spontaneously meeting with friends and colleagues online, using this Chrome extension.
  2. Funnies.page: Start your morning with some humor by getting five new comics from artists around the world, delivered daily to your inbox.
  3. Web.page: Find design inspiration, trends and techniques for building websites.
  4. Volition.page: Track your goals and progress any time, anywhere with this web app.
  5. Byline.page: Interested in creative writing? Try this multiplayer app, where you build stories line by line, knowing only what the previous author wrote.

Make .dev(elopment) a breeze:

  1. Projectjob.dev: Find and hire developers that are a perfect match for your requirements by exploring the work they’ve done before.
  2. Htmldom.dev: Try this handy reference for manipulating web pages using Javascript.
  3. Nodesign.dev: Use existing design tools to complete your development project.
  4. Practice.dev: If practice makes perfect, you can improve your skills by solving real web development challenges and learn by doing.
  5. Daily.dev: Get the latest developer news from tech blogs on any topic you can think of, all in one place.

Happy New Year from all of us at Google Registry! We hope these websites and apps help you get the most out of 2021.

Community leaders upskill themselves and find new roles with Elevate by Google Developers

Posted by Kübra Zengin, GDG North America Regional Lead

Image of participants in a recent Elevate workshop.

The North America Developer Ecosystem team recently hosted Elevate for Google Developer Groups organizers and Women Techmakers Ambassadors in US & Canada. The three-month professional development program met every Wednesday via Google Meet to help tech professionals upskill themselves with workshops on leadership, communication, thinking, and teamwork.

The first cohort of the seminar-style program recently came to a close, with 40+ Google Developer Groups organizers and Women Techmakers Ambassadors participating. Additionally, 18 guest speakers - 89% of whom were underrepresented genders - hosted specialized learning sessions over three months of events.

Elevate is just one example of the specialized applied skills training available to the Google Developer Groups community. As we look ahead to offering Elevate again in 2021, we wanted to share with you some of the key takeaways from the first installment of the program.

What the graduates had to say

From landing new roles at companies like Twitter and Accenture, to negotiating salary raises, the 40 graduates of Elevate have seen many successes. Here’s what a few of them had to say:

“I got a role at Accenture as a software engineer because I used the learnings from Elevate when applying and interviewing for the job. I can't thank the Google team enough!”

“The interactive workshops truly helped me land my new job at Twitter.”

“After the Elevate trainings on negotiation, I successfully secured a higher salary with my new employer.”

Whether it’s finding new jobs or moving to new countries, Elevate’s graduates have used their new skills to guide their careers towards their passions. Check out a few of the program’s key lessons below:

Bringing your best self to the table

One major focus of the program was to help community leaders develop their own professional identity and confidence by learning communication techniques that would help them stand out and define themselves in the workplace.

Entire learning sessions were dedicated to specific value-adding topics, including:

  • How to use persuasive body language;
  • Finding a networking, presenting, and storytelling voice;
  • The best practices for salary negotiation.

Along with other sessions on growth mindsets, problem solving, and more, attendees gained a deeper understanding of the best ways to present themselves, their ideas, and their worth in a professional setting - an essential ability that many feel has already helped them navigate job markets with more precision.

A team that feels valued brings value

“Who is on a team matters less than how the team members interact, structure their work, and view their contributions.”

The advice above, offered by a guest speaker during a teambuilding session, was one of the quotes that resonated with participants the most during the program. The emphasis on how coworkers think of each other and the best ways to build a culture of ownership over a team’s wins and losses embodies the key learnings central to Elevate’s mission.

The program further emphasized this message with learning sessions on:

  • Giving and accepting clear feedback;
  • Bias busting and empathy training in the workplace;
  • Conflict management and resolution.

With these trainings, paired with others on growth mindsets and decision making, Elevate’s participants were able to start analyzing the effectiveness of different work environments on productivity. Through breakout sessions, they quickly realized that the more secure and supported an employee feels, the more willing they are to go the extra mile for their team. Equipped with this new knowledge base, many participants have already started bringing these key takeaways to their own workplaces in an effort to build more inclusive and productive cultures.

Whether it’s finding a new role or improving your applied skills, we can’t wait to see how Google Developer programs can help members achieve their professional goals.

For similar opportunities, find out how to join a Google Developer Group near you, here. And register for upcoming applied skills trainings on the Elevate website, here.

Solve for the United Nations’ Sustainable Development Goals with Google technologies in this year’s Solution Challenge.

Posted by Erica Hanson, Global Program Manager, Google Developer Student Clubs

Solution Challenge image

Created by the United Nations in 2015 to be achieved by 2030, the 17 Sustainable Development Goals (SDGs) agreed upon by all 193 United Nations Member States aim to end poverty, ensure prosperity, and protect the planet.

Last year brought many challenges, but it also brought a greater spirit around helping each other and giving back to our communities. With that in mind, we invite students around the world to join the Google Developer Student Clubs 2021 Solution Challenge!

If you’re new to the Solution Challenge, it is an annual competition that invites university students to develop solutions for real world problems using one or more Google products or platforms.

This year, see how you can use Android, TensorFlow, Google Cloud, Flutter, or any of your favorite Google technologies to promote employment for all, economic growth, and climate action, by building a solution for one or more of the UN Sustainable Development Goals.

What winners of the Solution Challenge receive

Participants will receive specialized prizes at different stages:

  1. The Top 50 teams will receive mentorship from Google and other experts to further work on their projects.
  2. The Top 10 finalists will receive a 1-year subscription to Pluralsight, swag, additional customized mentoring from Google, and a feature in the Google Developers Blog and Demo Day live on YouTube.
  3. The 3 Grand Prize Winners will receive all the prizes included in the Top 10 category along with a Chromebook and a private team meeting with a Google executive.

How to get started on the Solution Challenge

There are four main steps to joining the Solution Challenge and getting started on your project:

  1. Register at goo.gle/solutionchallenge and join a Google Developer Student Club at your college or university. If there is no club at your university, you can join the closest one through the event platform.
  2. Select one or more of the United Nations 17 Sustainable Development Goals to solve for.
  3. Build a solution using Google technology.
  4. Create a demo and submit your project by March 31, 2021.

Resources from Google for Solution Challenge participants

Google will provide Solution Challenge participants with various resources to help students build strong projects for their contest submission.

  • Live online sessions with Q&As
  • Mentorship from Google, Google Developer Experts, and the Developer Student Club community
  • Curated codelabs designed by Google Developers
  • Access to Design Sprint guidelines developed by Google Ventures
  • and more!

When are winners announced?

Once all the projects are submitted after the March 31st deadline, judges will evaluate and score each submission from around the world using the criteria listed on the website. From there, winning solutions will be announced in three rounds.

Round 1 (May): The Top 50 teams will be announced.

Round 2 (July): After the top 50 teams submit their new and improved solutions, 10 finalists will be announced.

Round 3 (August): In the finale, the top 3 grand prize winners will be announced live on YouTube during the 2021 Solution Challenge Demo Day.

With a passion for building a better world, savvy coding skills, and a little help from Google, we can’t wait to see the solutions students create.

Learn more and sign up for the 2021 Solution Challenge, here.

Announcing New Smart Home App Discovery Features

Posted by Toni Klopfenstein, Developer Advocate

When a user connects a smart device to the Google Assistant via the Home app, the user must select the appropriate related Action from the list of all available Actions. The user then clicks through multiple screens to complete their device setup. Today, we're releasing two new features to improve this device discovery process and drive customer adoption of your Smart Home Action through the Google Home app. App Discovery and Deep Linking are two convenience features that help users find your Google-Assistant compatible smart devices quickly and onboard faster.

App Discovery enables users to quickly find your smart home Action thanks to suggestion chips within the Google Home app. You can implement this new feature through the Actions Console by creating a verified brand link between your Action, your website, and your mobile app. App Discovery doesn't require any coding work to implement, making this a development-light feature that provides great improvements to the user experience of device linking.

In addition to helping users discover your Action directly through suggestion chips, Deep Linking enables you to guide users to your account linking flow within the Google Home app in one step. These deep links are easily added to your mobile app or web content, guiding users to your smart home integration with a single tap.

Deep Linking and App Discovery can help you create a more streamlined onboarding experience for your users, driving increased engagement and user satisfaction, and can be implemented with minimal engineering work.

To implement App Discovery and Deep Linking for your Smart Home Action, check out the developer documents, or watch the video covering these new features.

You can also check out the smart home codelabs if you are just starting to build out your Action.

We want to hear from you, so continue sharing your feedback with us through the issue tracker, and engage with other smart home developers in the /r/GoogleAssistantDev community. Follow @ActionsOnGoogle on Twitter for more of our team's updates, and tweet using #AoGDevs to share what you’re working on. We can’t wait to see what you build!

A Google for Startups Accelerator for startups using voice technology to better the world

Posted by Jason Scott, Head of Startup Developer Ecosystem, U.S., Google

At Google, we have long understood that voice user interfaces can help millions of people accomplish their goals more effectively. Our journey in voice began in 2008 with Voice Search -- with notable milestones since, such as building our first deep neural network in 2012, our first sequence-to-sequence network in 2015, launching Google Assistant in 2016, and processing speech fully on device in 2019. These building blocks have enabled the unique voice experiences across Google products that our users rely on everyday.

Voice AI startups play a key role in helping build and deliver innovative voice-enabled experiences to users. And, Google is committed to helping tech startups deliver high impact solutions in the voice space. This month, we are excited to announce the Google for Startups Accelerator: Voice AI program, which will bring together the best of Google’s programs, products, people and technology with a joint mission to advance and support the most promising voice-enabled AI startups across North America.

As part of this Google for Startups Accelerator, selected startups will be paired with experts to help tackle the top technical challenges facing their startup. With an emphasis on product development and machine learning, founders will connect with voice technology and AI/ML experts from across Google to take their innovative solutions to the next level.

We are proud to launch our first ever Google for Startups Accelerator: Voice AI -- building upon Google’s longstanding efforts to advance the future of voice-based computing. The accelerator will kick off in March 2021, bringing together a cohort of 10 to 12 innovative voice technology startups. If this sounds like your startup, we'd love to hear from you. Applications are open until January 28, 2021.

Announcing gRPC Kotlin 1.0 for Android and Cloud

Posted by Louis Wasserman, Software Engineer and James Ward, Developer Advocate

Kotlin is now the fourth "most loved" programming language with millions of developers using it for Android, server-side / cloud backends, and various other target runtimes. At Google, we've been building more of our apps and backends with Kotlin to take advantage of its expressiveness, safety, and excellent support for writing asynchronous code with coroutines.

Since everything in Google runs on top of gRPC, we needed an idiomatic way to do gRPC with Kotlin. Back in April 2020 we announced the open sourcing of gRPC Kotlin, something we'd originally built for ourselves. Since then we've seen over 30,000 downloads and usage in Android and Cloud. The community and our engineers have been working hard polishing docs, squashing bugs, and making improvements to the project; culminating in the shiny new 1.0 release! Dive right in with the gRPC Kotlin Quickstart!

For those new to gRPC & Kotlin let's do a quick runthrough of some of the awesomeness. gRPC builds on Protocol Buffers, aka "protos" (language agnostic & high performance data interchange) and adds the network protocol for efficiently communicating with protos. From a proto definition the servers, clients, and data transfer objects can all be generated. Here is a simple gRPC proto:

message HelloRequest {
string name = 1;
}

message HelloReply {
string message = 1;
}

service Greeter {
rpc SayHello (HelloRequest) returns (HelloReply) {}
}

In a Kotlin project you can then define the implementation of the Greeter's SayHello service with something like:

object : GreeterGrpcKt.GreeterCoroutineImplBase() {
override suspend fun sayHello(request: HelloRequest) =
HelloReply
.newBuilder()
.setMessage("hello, ${request.name}")
.build()
}

You'll notice that the function has `suspend` on it because it uses Kotlin's coroutines, a built-in way to handle async / reactive IO. Check out the server example project.

With gRPC the client "stubs" are generated making it easy to connect to gRPC services. For the protoc above, the client stub can be used in Kotlin with:

val stub = GreeterCoroutineStub(channel)
val request = HelloRequest.newBuilder().setName("world").build()
val response = stub.sayHello(request)
println("Received: ${response.message}")

In this example the `sayHello` method is also a `suspend` function utilizing Kotlin coroutines to make the reactive IO easier. Check out the client example project.

Kotlin also has an API for doing reactive IO on streams (as opposed to requests), called Flow. gRPC Kotlin generates client and server stubs using the Flow API for stream inputs and outputs. The proto can define a service with unary streaming or bidirectional streaming, like:

service Greeter {
rpc SayHello (stream HelloRequest) returns (stream HelloReply) {}
}

In this example, the server's `sayHello` can be implemented with Flows:

object : GreeterGrpcKt.GreeterCoroutineImplBase() {
override fun sayHello(requests: Flow<HelloRequest>): Flow<HelloReply> {
return requests.map { request ->
println(request)
HelloReply.newBuilder().setMessage("hello, ${request.name}").build()
}
}
}

This example just transforms each `HelloRequest` item on the flow to an item in the output / `HelloReply` Flow.

The bidirectional stream client is similar to the coroutine one but instead it passes a Flow to the `sayHello` stub method and then operates on the returned Flow:

val stub = GreeterCoroutineStub(channel)
val helloFlow = flow {
while(true) {
delay(1000)
emit(HelloRequest.newBuilder().setName("world").build())
}
}

stub.sayHello(helloFlow).collect { helloResponse ->
println(helloResponse.message)
}

In this example the client sends a `HelloRequest` to the server via Flow, once per second. When the client gets items on the output Flow, it just prints them. Check out the bidi-streaming example project.

As you've seen, creating data transfer objects and services around them is made elegant and easy with gRPC Kotlin. But there are a few other exciting things we can do with this...

Android Clients

Protobuf compilers can have a "lite" mode which generates smaller, higher performance classes which are more suitable for Android. Since gRPC Kotlin uses gRPC Java it inherits the benefits of gRPC Java's lite mode. The generated code works great on Android and there is a `grpc-kotlin-stub-lite` artifact which depends on the associated `grpc-protobuf-lite`. Using the generated Kotlin stub client is just like on the JVM. Check out the stub-android example and android example.

GraalVM Native Image Clients

The gRPC lite mode is also a great fit for GraalVM Native Image which turns JVM-based applications into ahead-of-time compiled native images, i.e. they run without a JVM. These applications can be smaller, use less memory, and start much faster so they are a good fit for auto-scaling and Command Line Interface environments. Check out the native-client example project which produces a nice & small 14MB executable client app (no JVM needed) and starts, connects to the server, makes a request, handles the response, and exits in under 1/100th of a second using only 18MB of memory.

Google Cloud Ready

Backend services created with gRPC Kotlin can easily be packaged for deployment in Kubernetes, Cloud Run, or really anywhere you can run docker containers or JVM apps. Cloud Run is a cloud service that runs docker containers and scales automatically based on demand so you only pay when your service is handling requests. If you'd like to give a gRPC Kotlin service a try on Cloud Run:

  1. Deploy the app with a few clicks
  2. In Cloud Shell, run the client to connect to your app on the cloud:
    export PROJECT_ID=PUT_YOUR_PROJECT_ID_HERE
    docker run -it gcr.io/$PROJECT_ID/grpc-hello-world-mvn \
    "java -cp target/classes:target/dependency/* io.grpc.examples.helloworld.HelloWorldClientKt YOUR_CLOUD_RUN_DOMAIN_NAME"

Here is a video of what that looks like:

Check out more Cloud Run gRPC Kotlin examples

Thank You!

We are super excited to have reached 1.0 for gRPC Kotlin and are incredibly grateful to everyone who filed bugs, sent pull requests, and gave the pre-releases a try! There is still more to do, so if you want to help or follow along, check out the project on GitHub.

Also huge shoutouts to Brent Shaffer, Patrice Chalin, David Winer, Ray Tsang, Tyson Henning, and Kevin Bierhoff for all their contributions to this release!