Voice to Text In Android App And Web App

I was interested in adding a voice input field that will convert the voice to text, is there any way of adding it using any component? Or using some script?