At the time of typing email id if its email id exists in the system then throw error message

i have ‘email’ field which id unique field when user enter same email id which is existing in the system then under ‘email’ field give message

At the time of typing email id if email id exists in the system then throw error message
no need to click on ‘Save’ button and after show message