11

Is it possible to play some default sounds, such as when an incoming SMS/push is received?

If iOS SDK does not bundle these sound files, where can I download the same sounds?

samwize
  • 23,611
  • 14
  • 136
  • 181

1 Answers1

26

Yes it is possible, but they use undocumented enum values, that means you should not use it on AppStore apps.

AudioServicesPlaySystemSound(1003);

iOS SDK does not bundle these sound files, but you can find them on the device in the /System/Library/Audio/UISounds/ folder. However, I believe these files are copyrighted.

Why not create a sound yourself?

kennytm
  • 491,404
  • 99
  • 1,053
  • 989
  • I would like to play the exact similar sound, so looking for the easiest way. I have seen a lot of messaging app playing the sound too, and wonder how they do it eg. whatsapp. – samwize Mar 10 '11 at 09:01
  • 5
    Just a quick note: On iOS 5, I found that using 1007 gave me the standard Tri-Tone notification sound (same as my push notify sound) – Michael Petrov Apr 16 '12 at 02:09
  • Thanks for the good answer. If you're using the sound for debugging purposes, it's easier to just use a simple system beep if one's available, instead of creating your own. – Phil Oct 08 '14 at 21:54
  • So there is no way to use a default notification sound without using an undocumented value? If I want to play the user default push notification sound, within my app, is this at all possible? – Brian Sep 10 '15 at 03:20