Share your experience!
However, if it hasn't worked since the beginning or if the jack has gotten damaged you may have a hardware issue that needs to be repaired. If so you should contact Sony Xperia Support.
http://support.sonymobile.com/global-en/contactUs/
Hi PeterPa,
Welcome to the community! Since you're new please be sure that you have checked out our Discussion guidelines.
You could also try clearing the Smart Connect application to see if this app based,
Menu > Settings > Apps > All > Smart Connect > Clear Data
let us know how you get on.
I have noticed that no one has recommended this yet; if you have not sent it in for repair yet please simply try cleaning the headphone jack gently with something soft like a cotton tip.