# WaniKani Context Sentence Google TTS (Text-To-Speech)

**URL:** <https://community.wanikani.com/t/wanikani-context-sentence-google-tts-text-to-speech/71841>\
**Category:** API And Third-Party Apps\
**Created:** [October 1, 2025, 1:20am UTC](https://community.wanikani.com/t/wanikani-context-sentence-google-tts-text-to-speech/71841 "2025-10-01T01:20:53Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![MichaelCharles](https://sea1.discourse-cdn.com/wanikanicommunity/user_avatar/community.wanikani.com/michaelcharles/32/827818_2.png) [@MichaelCharles](https://community.wanikani.com/u/MichaelCharles)\
**Post date:** [October 1, 2025, 1:20am UTC](https://community.wanikani.com/t/wanikani-context-sentence-google-tts-text-to-speech/71841/1 "2025-10-01T01:20:53Z")

</div>

I threw together a userscript that adds text-to-speech buttons to Japanese context sentences in WaniKani. Click the 🔊 button next to any Japanese sentence to hear it spoken aloud using Google’s Neural2 Japanese voices at 80% speed.

You must update the script with a valid API key from [Google Cloud Console](https://console.cloud.google.com/).

1. Create a new project or select an existing one

2. Enable the “Cloud Text-to-Speech API” for your project

3. Go to “APIs & Services” \> “Credentials”

4. Click “Create Credentials” \> “API Key”

5. Copy the API key and replace the value for `ttsApiKey` in the userscript.

The playback speed is also configurable by changing the value of the `speakingRate` variable, where 1 is 100% speed. The default value is 0.8 setting it to 80% speed.

Additionally, you can use one of three voices and can configure this with the `voice` variable. The default value is “ja-JP-Neural2-C”, but “ja-JP-Neural2-B” and “ja-JP-Neural2-D” are also valid voices.

It looks like this

 ![Screenshot 2025-10-01 at 9.56.40](https://global.discourse-cdn.com/wanikanicommunity/original/4X/d/e/7/de774b772725bb7decc2c8bd51dae839acb52a44.png)

And sounds like [this](https://files.michaelcharl.es/e85d80ff-273a-44f9-a320-51d98e10266d.mp3) (click the link for an audio sample).

[Install it from Greasy Fork](https://greasyfork.org/en/scripts/551202-wanikani-context-sentence-google-tts).

---

<div class="post-metadata">

**Author:** ![MichaelCharles](https://sea1.discourse-cdn.com/wanikanicommunity/user_avatar/community.wanikani.com/michaelcharles/32/827818_2.png) [@MichaelCharles](https://community.wanikani.com/u/MichaelCharles)\
**Post date:** [October 1, 2025, 8:48am UTC](https://community.wanikani.com/t/wanikani-context-sentence-google-tts-text-to-speech/71841/2 "2025-10-01T08:48:03Z")

</div>

I really like hearing audio for example sentences, and Google’s TTS is fairly natural, so I’m really excited about this, personally. If only I end up using it I’ll certainly be happy, but I hope if there was anyone else out there that wanted audio for context sentences that this is helpful for them as well.

---

<div class="post-metadata">

**Author:** ![codejockie](https://sea1.discourse-cdn.com/wanikanicommunity/user_avatar/community.wanikani.com/codejockie/32/686603_2.png) [@codejockie](https://community.wanikani.com/u/codejockie)\
**Post date:** [October 2, 2025, 3:46pm UTC](https://community.wanikani.com/t/wanikani-context-sentence-google-tts-text-to-speech/71841/3 "2025-10-02T15:46:02Z")

</div>

Reading your post, I realised this feature should be added to _ **Mina** _ the android app for WK. This feature will be part of the next round of features and changes to the app.

Since I was inspired by you, I followed your model. Thank you!

 ![CS_TTS](https://global.discourse-cdn.com/wanikanicommunity/original/4X/0/f/1/0f1cae31c96aa8df8982c9476a0a3365f051873a.png)

---

<div class="post-metadata">

**Author:** ![MichaelCharles](https://sea1.discourse-cdn.com/wanikanicommunity/user_avatar/community.wanikani.com/michaelcharles/32/827818_2.png) [@MichaelCharles](https://community.wanikani.com/u/MichaelCharles)\
**Post date:** [October 3, 2025, 4:45am UTC](https://community.wanikani.com/t/wanikani-context-sentence-google-tts-text-to-speech/71841/4 "2025-10-03T04:45:32Z")

</div>

That’s awesome! If it weren’t for the fact that I’m on iOS I’d go check it out 😅
