Hazrath Ali (R.A) Said there is one deed if you do it sincerely with devotion Allah will answer all your prayers.
And people questioned what is that.
Moula Ali replied, “Those who forbid speaking lies permanently Allah will answer whatever prayer comes onto his or her tongue.”
We speak lies when we fear punishment, and we speak lies to avoid facing embarrassing situations we also speak lies to avoid conflicts arising out of it. But we do not realize that whenever we speak lies we disappoint Allah and angels of mercy smell a bad odor coming from our mouths so they move away and fly away from us.
But sometimes it is an exception and necessity to speak lies:
especially if you are speaking lies to avoid committing sin or stopping sin and if you are speaking lies to save someone`s life or you are saying lies for some good and noble purpose then in this situation Allah will not be displeased with you.
But if you are telling lies just to please others or just for fun and timepass or for some selfish purposes then this is a major sin and you must ask Allah to forgive you for this sin.
Whatever there is in our hearts Allah knows best.