# Vibration duration for mobile devices in Unity

I'm used the Handheld.Vibrate() method. I know that if you call it several times, you can increase the vibration time, but when it is called once, the vibration lasts about 1 second. But I would like to make an imitation of clicking on the android keyboard. (Vibration ~ 0.2s)

How to set the duration of the vibration?

• What platform are you targeting? (I do not think there is a platform agnostic solution) – Theraot Nov 30 '19 at 3:22
• After looking around the Unity community, apparently the recommendation is to get a plug-in from the Asset Store. You can find them under "Tools" -> "Integration", search for "Vibration" or "Haptic Feedback". – Theraot Nov 30 '19 at 4:00
• basically ios has many different types of vibration but android has only basic vibration. in unity only HandHeld.Vibrate() works in both of them. that vibrates phone in 0.5 seconds. if you you want to vibrate in a wanted length, just make a coroutine thatvibrates phone in wanted seconds – virtouso Nov 30 '19 at 6:57
• @Theraot that looks like an upvote-worthy answer, especially if you can include a summary of one of these plug-ins or citation of this recommendation. – DMGregory Nov 30 '19 at 13:39
• @virtouso as we can read in OP's question, they want a shorter vibration than the default, not a longer one. – DMGregory Nov 30 '19 at 13:40