This question already has an answer here:

In Windows I can do these steps:

1. Open Notepad
2. Copy and Paste 


3. Save it as xyz.vbs
4. Run it/Open it

It will then speak "Hello". Is there something like this in Ubuntu?

marked as duplicate by Avinash Raj, Seth, TrailRider, BuZZ-dEE, Olli Feb 12 '14 at 10:22

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.


Install the espeak Install espeak package. Then run in a terminal

espeak -v en "Hello"

To change the voice, please refer to the manpage. An excerpt from man espeak:

   --voices[=<language code>]
          Lists  the available voices. If =<language code> is present then only
          those voices which are suitable for that language are listed.

   -v <voice name>
          Use voice file of this name from espeak-data/voices
  • Can I change the voice ? – Unbound Feb 11 '14 at 9:24
  • @AvinashRaj Where is that requirement given in the question? And for this example he provided in Windows you'll need Visual Basic scripting and speech synthesis components installed. – gertvdijk Feb 11 '14 at 9:28
  • 2
    Is there any option for female vooice? – Unbound Feb 11 '14 at 9:38

There is a link which will give detailed text to speech command line tools.


The first speech package I tried was Festival. It worked fine and produces a voice like a rough sounding robot.

Festival Text to Speech

Install Festival with:

sudo apt-get install festival

Try out Festival with:

echo “Just what do you think you're doing, Dave?” | festival --tts

Espeak Text to Speech Espeak is a more modern speech synthesis package than Festival. It sounds clearer but does wail a little. If you are making an alien or a RPi witch then it’s the one for you! Seriously it is a good allrounder with great customisation options.

Install Espeak with:

sudo apt-get install espeak 

Test Espeak with: English female voice, emphasis on capitals (-k), speaking slowly (-s) using direct text:-

espeak -ven+f3 -k5 -s150 "I've just picked up a fault in the AE35 unit"

Not the answer you're looking for? Browse other questions tagged or ask your own question.