
Stop Gmail from Wrapping Your Phone Number into Text Links
Both the desktop and mobile version(s) of Gmail now insert an anchor link around phone numbers.
In the desktop version, the link opens Google’s new voice/chat console which is displayed along the right column of the Gmail interface.
In mobile versions, the link opens up the mobile phone console with your phone number pre-populated making it very easy to dial numbers directly from your email.
Each of the following formats will get converted to links:
212.389.3934
(800) 389-3934
1-800-389-3934
(212) 389-3934
212–389–3934
212—389—3934
212–389–3934
212–389–3934
1–212–389–3934
212 -389 -3934
So how do you get around it?
1.) Use an HTML entity in your phone number that Gmail does not recognize:
In the example above I used the following entity just before each dash: “­”
In the example above I used: “­”
Unfortunatly, this HTML entity renders a dash “-” in Lotus Notes 6.5 and 7 (only) so the phone number appears like this: 212–389–3934
2.) Wrap an anchor tag around the phone number with an inline style that matches the rest of your text:
3.) If it’s possible, use the text version of the phone number:
If you can find any additional ways to bypass the text links in Gmail, don’t hesitate to share them below!
So change name@test.com to:
name@test­.com
Change www.mydomain.com to:
www.mydomain­.com
Change http://www.mydomain.com to:
http:­//www.mydomain­.com
Author: Kyle Lapaglia
Author: Kyle Lapaglia
33 thoughts on “Stop Gmail from Wrapping Your Phone Number into Text Links”
Comments are closed.
This is great. Just implement the first work around in our enewsletter template. Much appreciated!
You could use spans to achieve the same thing. Set som span-tags around both parenthesis for example. (else span inside the phone number somewhere should work)
Is there anything that might work in email signatures?
Just use an anchor tag leaving the href completely out. content. It will show up as a clickable link in hotmail, but do nothing when clicked on. It won’t show up as a link at all on any other email client (yahoo, outlook, gmail….)
I found in stackoverflow.com a less intrusive way to resolve it. You can use html tags around ‘.’ or ‘@’ to avoid gmail to convert to links. It may wark also with phone numbers.
You can permanently turn off this feature by going into
Settings–> Chat–> Call Phones: Disable Outbound Outbound Voice Calling
You can use middle dots (·) instead of periods:
212·389·3934
Great idea Dano! Works great.
The or method does not work for me. The method does, however.
I just replace all “.” with “.” in a text with many numbers (readings, not phone numbers).
You can permanently turn off this feature by going into
Settings–> Chat–> Call Phones: Disable Outbound Outbound Voice Calling
THANK YOU!!!!!!!!!!!!!!!!!!!!
It was infuriating.
@IndyRon & DLM: However helpful that may be to others searching how to disable it on THEIR client-side, the issue here is what gets to be seen on the customer’s device (which probably DIDN’T disable that “feature”).
@author: Thanks so much! It’s funny because just before I searched and fell here, I tried the HTML entities for the numbers themselves but Gmail still recognized them (which is reassuring in some way).
Does this interfere with the ability of a mobile phone user to dial a number? (We don’t want them to stop calling us, only for Google to stop turning our phone numbers blue!)
Thnx for such an intersting post Michelle. I just triend it in personal blog. Its working great thanks again. Steve
Fathom: You brought up a VERY good point. Since most people check their email on their smartphones, the chances of them clicking on a phone number might decrease because the phone number doesn’t look ‘accessible.’
One would have to decide the best way for their subscribers to contact them… via phone or email… then code and style the HTML accordingly.
To add the style you wish on a phone number and keep the tap to call function on a mobile, you have to consider the phone number as a link, into a class.
Like this :
HTML :
CSS :
.call {
font-family:Arial, Helvetica, sans-serif;
font-size:12px;
color:#FFF;
}
.call a {
color:#FFF;
text-decoration:none;
}
Tested on iOS and Android.
Hope this will help !
The following CSS and HTML code will allow you to style your phone number anyway you wish while also keeping the tap to call function on mobile.
1. Insert the following <style> tag within the <head> tag:
<style type=”text/css”>
.ii a {text-decoration:none; color:#464646 !important;}
</style>
2. Wrap the telephone number with an tag. Then add a class name plus an inline style to the .
Example:
1.555.555.5555
This was tested in all major web browsers plus iOS and Android.
thanks for the post.
What about dates? No one would want to add my dated enewsletter to their calendar. Links to mmm dd, yyyy so I tried Euro dd mmm yyyy but still links. I’d prefer not to do mm/dd/yy. Thanks for any suggestions
In my situation, I needed two different colors for different locations where I had the phone number listed. What worked for me was to wrap the phone # with what Gmail is going to wrap it with anyway, then add a span tag with the style applied (otherwise the span was added outside the link).
888-555-1234
Although I told it text-decoration:none, I still got a thin blue underline so I added this to my stylesheet:
.ii a[href] {text-decoration:none;}
If I only had one color to deal with, adding the color to that bit would perhaps be all I needed to do.
As far as I can tell, this works for inline date and time:
JUL 17, 2013 =
JUL 17, 2013
(4:02 mins.) =
(4:02 mins.)
I don’t mind Gmail converting phone numbers to a link, I just want it to be styled the same as other links in the same section. What I don’t want to do is set phone numbers to look like links to nowhere in all email clients. Is there a way to simply overwrite Gmail’s default link styling? Or are my only options to have the number look like a link in all clients or to not look like a link in any?
Hello, Gmail is parsing numbers that look like phones but aren’t also. I’ve tested adding a between all the numbers and didn’t work, gmail continue on parsing as phone number.
I think this solution is not working anymore
What about?
123-456-7890
Isn’t it amazing, all the automatic stuff that Google does to our stuff these days?
I saved my phone number from being converted by wrapping parts of it in spans:
031 412 61 18
Great Idea , thank you
Another thank you! Worked great for a recent e-mail template.
Here’s my current method that works:
800-555-1234
Plus this in my style sheet:
/* Gmail Fix */
.ii a[href] {
text-decoration:none; !important;
color: #001;
}
I’m not certain I need the tag … I might even be using that for another reason, or maybe it’s something I tried in the past. So it may be overkill, but it works (for now).
9/29/14
Noticed this morning that it looks like gmail has implemented new email reader code that breaks these work arounds. I’m using styled and tags and gmail is still adding their own blue hyperlink.
SO annoying… has anyone else noticed this?
Ha, this seems to work- breaking the phone number into separate hyperlinks- a lot of work, so thanks for that google. I use the span, because yahoo adds their own bland style to hyperlinks if you don’t- thanks fro that yahoo.
(123) 456–7890
You could also simply copy Gmail’s output of the phone number, paste that to your template and add a style-attribute in it, styling it as not being recognizable as a link.
If you want to hide the pointer, add “cursor: default” to your inline style.
This seems to do the trick as well. Choosing an html tag that is not used anywhere else on the page.
i a {
color:#ffffff !important;
text-decoration:none !important;
}
——
201 555 4444
I used this with success:
<?php echo substr($telephone,0,1); ?><?php echo substr($telephone,1); ?>
Detaches the first character from the rest making it incomprehensible as a phone number.
Just use a tag like to wrap the text you don’t want to autolink, like
http://www.mysupersite .com