Question

cant set gmail for my php applicaiton. Gmail prevent all signin attempts from my server

i have a php application from where users can send email notification to their customers. users can send email using their yahoo or other email hosting but they are having problem on gmail and hotmail. when they try to authenticate their gmail address gmail simply disallow it. when i check gmails device activity and notifications section for that email address, i found “Sign-in attempt prevented by Google” for all the requests from my server ip.

how can i resolve this issue?

Subscribe
Share

@newbie I found a link you’ll find useful. I don’t know your exact PHP implementation but here’s the OAuth2.0 webpage: http://oauth.net/2/ … Scroll down to Client Libraries and that should give you some idea.

@newbie lemme see what i can find… Outlook.com doesn’t seem to implement something that would cause this so I’m stumped on that.

This comment has been deleted

@delrakkin254 thanks a lot for your reply.

i have been trying all the solutions and got lucky only once.

by the way, can you point me any tutorial how can i implement OAuth2.0 for my application?

@newbie I think i know the issue with Gmail, but not necessarily Hotmail… I’ll look into the hotmail side. Anyways, for Gmail: https://support.google.com/accounts/answer/6010255?hl=en <— follow those instructions if you control all the applicable gmail accounts or have your customers do it to allow your server to properly send emails from gmail. Apparently, Google wants OAuth2.0 implementations instead of POP3, IMAP, and SMTP which a lot of Mail Client developers are fighting tooth and nail because of the implications from implementation. I will look at hotmail’s stuff but it’s probably similar.

@jsamuel thanks for your reply. but i dont want use any other service at the moment.

i m trying to use simple php mailer to send emails of my user. my users can add other email address except gmail.

Is it an option to instead use a mail sending service such as SendGrid?


Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

This question was answered by @vedalken254:

@newbie I think i know the issue with Gmail, but not necessarily Hotmail… I’ll look into the hotmail side. Anyways, for Gmail: https://support.google.com/accounts/answer/6010255?hl=en <— follow those instructions if you control all the applicable gmail accounts or have your customers do it to allow your server to properly send emails from gmail. Apparently, Google wants OAuth2.0 implementations instead of POP3, IMAP, and SMTP which a lot of Mail Client developers are fighting tooth and nail because of the implications from implementation. I will look at hotmail’s stuff but it’s probably similar.

View the original comment